UIKit0 / newsbeuter

Automatically exported from code.google.com/p/newsbeuter
0 stars 0 forks source link

segfault on html(escaped) in feed item title #258

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
example feed(google reader): 
http://www.google.com/reader/atom/feed/http%3A//www.reddit.com/r/web_design/.rss
?n=1000

feed item content:

<entry gr:crawl-timestamp-msec="1298999240165"><id 
gr:original-id="http://www.reddit.com/r/web_design/comments/fv52q/how_do_i_add_t
he_border_to_the_following/">tag:google.com,2005:reader/item/bd7ae1445bfd1fd6</i
d><category term="user/17559756174405716067/state/com.google/reading-list" 
scheme="http://www.google.com/reader/" label="reading-list"/><category 
term="user/17559756174405716067/label/art" 
scheme="http://www.google.com/reader/" label="art"/><category 
term="user/17559756174405716067/state/com.google/fresh" 
scheme="http://www.google.com/reader/" label="fresh"/><title type="html">How do 
I add the border to the following table(HTML): &lt;table cellpadding="0" 
cellspacing="0"&gt;&lt;/table&gt;</title><published>2011-03-01T16:52:24Z</publis
hed><updated>2011-03-01T16:52:24Z</updated><link rel="alternate" 
href="http://www.reddit.com/r/web_design/comments/fv52q/how_do_i_add_the_border_
to_the_following/" type="text/html"/><summary 
xml:base="http://www.reddit.com/r/web_design/" 
type="html">&lt;div&gt;&lt;p&gt;That's it. Anyone know how to add ab order? My 
HTML skills are very limited.&lt;/p&gt;&lt;/div&gt; submitted by &lt;a 
href="http://www.reddit.com/user/pumper911"&gt; pumper911 &lt;/a&gt; &lt;br&gt; 
&lt;a 
href="http://www.reddit.com/r/web_design/comments/fv52q/how_do_i_add_the_border_
to_the_following/"&gt;[link]&lt;/a&gt; &lt;a 
href="http://www.reddit.com/r/web_design/comments/fv52q/how_do_i_add_the_border_
to_the_following/"&gt;[7 comments]&lt;/a&gt;</summary><author 
gr:unknown-author="true"><name>(author unknown)</name></author><source 
gr:stream-id="feed/http://www.reddit.com/r/web_design/.rss"><id>tag:google.com,2
005:reader/feed/http://www.reddit.com/r/web_design/.rss</id><title 
type="html">web_design</title><link rel="alternate" 
href="http://www.reddit.com/r/web_design/" type="text/html"/></source></entry>

debug log:

[2011-03-02 10:28:05] DEBUG: rss_parser::parse: found enclosure_url:
[2011-03-02 10:28:05] DEBUG: rss_parser::parse: found enclosure_type:
[2011-03-02 10:28:05] DEBUG: rss_parser::parse: item title = `What books would 
you suggest to a new web designer?' link = 
`http://www.reddit.com/r/web_design/comments/fv59z/what_books_would_you_suggest_
to_a_new_web_designer/' pubDate = `Tue, 01 Mar 2011 18:01:01 +0100' 
(1298998861) description = `<div><p>I am an art major double concentrating in 
Graphic Design and New media (Web art and design, interactive art, motion 
graphics, digital video editing, game design, and three-dimensional 
modeling/printing.)</p> <p>I'm taking my second web design course now, and I'm 
terrified that I am nowhere near as knowlegable as I would like to 
be.</p></div> submitted by <a href="http://www.reddit.com/user/Soyburgers"> 
Soyburgers </a> <br> <a 
href="http://www.reddit.com/r/web_design/comments/fv59z/what_books_would_you_sug
gest_to_a_new_web_designer/">[link]</a> <a 
href="http://www.reddit.com/r/web_design/comments/fv59z/what_books_would_you_sug
gest_to_a_new_web_designer/">[7 comments]</a>'
[2011-03-02 10:28:05] INFO: rss_parser::parse: added article title = `What 
books would you suggest to a new web designer?' link = 
`http://www.reddit.com/r/web_design/comments/fv59z/what_books_would_you_suggest_
to_a_new_web_designer/' ign = 0x7fffd073e218
[2011-03-02 10:28:05] DEBUG: rss_parser::parse: found no content:encoded
[2011-03-02 10:28:05] DEBUG: rss_parser::set_item_content: content = submitted 
by <a href="http://www.reddit.com/user/magenta_placenta"> magenta_placenta </a> 
<br> <a href="http://lab.jeffbatterton.com/iphone-css3/">[link]</a> <a 
href="http://www.reddit.com/r/web_design/comments/fv593/css3_iphone_webkit_brows
er/">[1 comment]</a>
[2011-03-02 10:28:05] DEBUG: rss_parser::parse: found enclosure_url:
[2011-03-02 10:28:05] DEBUG: rss_parser::parse: found enclosure_type:
[2011-03-02 10:28:05] DEBUG: rss_parser::parse: item title = `CSS3 iPhone 
(webkit browser)' link = 
`http://www.reddit.com/r/web_design/comments/fv593/css3_iphone_webkit_browser/' 
pubDate = `Tue, 01 Mar 2011 17:59:42 +0100' (1298998782) description = 
`submitted by <a href="http://www.reddit.com/user/magenta_placenta"> 
magenta_placenta </a> <br> <a 
href="http://lab.jeffbatterton.com/iphone-css3/">[link]</a> <a 
href="http://www.reddit.com/r/web_design/comments/fv593/css3_iphone_webkit_brows
er/">[1 comment]</a>'
[2011-03-02 10:28:05] INFO: rss_parser::parse: added article title = `CSS3 
iPhone (webkit browser)' link = 
`http://www.reddit.com/r/web_design/comments/fv593/css3_iphone_webkit_browser/' 
ign = 0x7fffd073e218
[2011-03-02 10:28:05] DEBUG: parse_tag: parsing 'table cellpadding="0" 
cellspacing="0"', pos = 5, last_pos = 0
[2011-03-02 10:28:05] DEBUG: parse_tag: tag name = table
[2011-03-02 10:28:05] DEBUG: parse_tag: found = or space
[2011-03-02 10:28:05] DEBUG: parse_tag: found =
[2011-03-02 10:28:05] DEBUG: parse_tag: finding ending quote, pos = 21
[2011-03-02 10:28:05] DEBUG: parse_tag: extracted attribute is 
'cellpadding="0"', adding
[2011-03-02 10:28:05] DEBUG: parse_tag: found = or space
[2011-03-02 10:28:05] DEBUG: parse_tag: found =
[2011-03-02 10:28:05] DEBUG: parse_tag: finding ending quote, pos = 37
[2011-03-02 10:28:05] DEBUG: parse_tag: extracted attribute is 
'cellspacing="0"', adding
[2011-03-02 10:28:05] DEBUG: parse_tag: parsing '/table', pos = -1, last_pos = 0
[2011-03-02 10:28:05] DEBUG: parse_tag: tag name = /table

Original issue reported on code.google.com by moc...@gmail.com on 2 Mar 2011 at 9:59

GoogleCodeExporter commented 9 years ago
fixed in 8bdac5226037533a8e3e26634e0dca31edb8c3a9

Original comment by moc...@gmail.com on 3 Mar 2011 at 8:51