UNRESOLVED
Details
Assignee
ROME Jira LeadROME Jira LeadReporter
orpheusxorpheusxFix versions
Affects versions
Priority
Major
Details
Details
Assignee
ROME Jira Lead
ROME Jira LeadReporter
orpheusx
orpheusxFix versions
Affects versions
Priority
Created July 16, 2009 at 3:38 PM
Updated October 8, 2013 at 7:48 PM
Resolved July 16, 2009 at 3:38 PM
Twitter, like Google's Blog Search feeds, include a subset of OpenSearch tags in
their search based Atom feeds. However, they don't include a <startIndex> tag.
The code in
com.sun.syndication.feed.module.opensearch.impl.OpenSearchModuleParser assumes
that the tag exists and tries to parse it's value into an integer. The
<itemsPerPage> tag is handled the same way. This results in
NullPointerExceptions when parsing one of their feeds.
My reading of
http://www.opensearch.org/Specifications/OpenSearch/1.1#The_.22startIndex.22_element
leads me to believe that the parser should handle missing <startIndex> and
<itemsPerPage> without RuntimeExceptions.
The fix is simply:
80c80,81
< osm.setStartIndex(Integer.parseInt(e.getText()));
—
> if(e!=null)
> osm.setStartIndex(Integer.parseInt(e.getText()));