IQProvide

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?

Thanks!!

you need to look for the end tag of whatever you are parsing. That is how you know that you are done.