History
|
Log In
H
OME
B
ROWSE PROJECT
F
IND ISSUES
Q
UICK SEARCH:
Learn more about
Quick Search
Issue Details
(
XML
|
Word
|
Printable
)
Key:
BLOJSOM-114
Type:
Bug
Status:
Closed
Resolution:
Fixed
Priority:
Major
Assignee:
David Czarnecki
Reporter:
David Czarnecki
Watchers:
1
Operations
If you were
logged in
you would be able to see more operations.
blojsom
Empty elements cause NullPointerException in CommentAPI
Created:
31/Jan/06 01:08 PM
Updated:
31/Jan/06 02:13 PM
Component/s:
blojsom extensions
Affects Version/s:
blojsom 2.29
Fix Version/s:
blojsom 2.30
Browser:
N/A
Application Server:
N/A
JDK Version:
N/A
O/S Version:
N/A
Description
« Hide
via Erik Thauvin:
There's a bug in the Blojsom CommentAPI Servlet... I was looking at the
source to implement my own, and noticed that if an element is empty, it
throws a NPE.
http://cvs.sourceforge.net/viewcvs.py/blojsom/blojsom-2.0/extensions/src/org/blojsom/extension/comment/CommentAPIServlet.java?rev=1.16&view=markup
For example:
curl --header "Content-type: text/xml" --data
"<item><title>Test</title><author>
erik@thauvin.net
</author><description>Posted
via cURL.</description><link></link></item>"
"
http://www.blojsom.com/commentapi/david/of+the+day/quote/?permalink=Tomorrow-Silverchair.html
"
The <link/> element is empty, which is perfectly legal.
The problem is with the node.getFirstChild().getNodeValue() calls which
don't seem to like empty elements.
Description
via Erik Thauvin: There's a bug in the Blojsom CommentAPI Servlet... I was looking at the source to implement my own, and noticed that if an element is empty, it throws a NPE.
http://cvs.sourceforge.net/viewcvs.py/blojsom/blojsom-2.0/extensions/src/org/blojsom/extension/comment/CommentAPIServlet.java?rev=1.16&view=markup
For example: curl --header "Content-type: text/xml" --data "<item><title>Test</title><author>
erik@thauvin.net
</author><description>Posted via cURL.</description><link></link></item>" "
http://www.blojsom.com/commentapi/david/of+the+day/quote/?permalink=Tomorrow-Silverchair.html
" The <link/> element is empty, which is perfectly legal. The problem is with the node.getFirstChild().getNodeValue() calls which don't seem to like empty elements.
Show »
All
Comments
Change History
Sort Order:
[
Permlink
|
« Hide
]
David Czarnecki
- [
31/Jan/06 02:13 PM
]
Fixed in CVS.
[
Show »
]
David Czarnecki
- [
31/Jan/06 02:13 PM
] Fixed in CVS.