Ok, I’‘ve this problem. I’‘ve coded a class to implement my own IQProvider. I’‘ve a serious problem implementing IQ parseIQ(XmlPullParser parser). I need to add validation or something like. When I’‘m parsing the XML content of the IQ sometimes, for any unknown reason, the parser seems to consume the stream of the next message. The problem is that the message is not well formed, or I’‘m just continue asking for the next event, even when I’'m at the end of the document.
Could anybody help me to understand the parser? How can I detect an invalid XML stream? Should I add new conditions to detect the end of the message?