ItemProvider relies on incorrect behavior of MXParser, violating the contract of the XMLPullParser interface
Description
Environment
None
Attachments
3
Activity
Show:

Robin Collier April 29, 2013 at 11:41 AM
Sleep deprivation 8-(
Thanks for catching that, it is now fixed.

Florian Schmaus April 28, 2013 at 12:49 PM
Since I am unable to log in and comment in fisheye: Why was the code related to the items node removed?

Robin Collier April 27, 2013 at 3:38 PM
Good catch, glad it was found before the release instead of after.
Added the fix along with some test cases for parsing the item content.

Florian Schmaus April 23, 2013 at 9:55 PM
See https://github.com/Flowdalic/asmack/issues/35 for a bug report that was introduced with the new implementation of ItemProvider. Suggested fix and patch included.

Florian Schmaus February 19, 2013 at 10:21 AM
The same patch ignoring space fixes/changes.
This is the upstream issue of the aSmack issue #3.
The contract of the the XMLPullParser interface states that getText() should return null if the next element is a TAG, but MXParser does return a String containing the TAG. KXmlParser used on Android does follow the specification and doesn't show the behavior, therefore PubSub Items don't work in aSmack without a patch.
Hint for flow: Remove https://github.com/Flowdalic/asmack/blob/master/static-src/custom/org/jivesoftware/smackx/pubsub/provider/ItemProvider.java when this issue is fixed upstream.