Re: [xml] parsing problem

On Mon, Jan 30, 2006 at 10:20:56PM +0000, Graham Bennett wrote:
Hi all,

I'm having a problem parsing the attached document with libxml 2.6.22.
My application uses the SAX2 interface in push mode, but for some reason 
I'm only able to reproduce it using xmllint --stream:

$ xmllint --stream badcomment.xml
badcomment.xml:17: parser error : Comment not terminated
<!-->Char</nt>* ']]&gt;' <nt def='NT-Char'>Char</nt>*)
badcomment.xml : failed to parse

The test case is somewhat fragile (but I'm fairly sure it's well-formed) 
- if I try to cut it down to a smaller doc it doesn't happen.  I'm
wondering if it's exposing some buffering problem in the parser.

Any ideas?

  Hum, strange. It is actually well formed since
is not ended as a comment. But running xmllint from CVS head on it
seems to work well, in normal, push or stream mode. Maybe you're heading
a specific bug present in libxml2 push mode, I remember fixing something
about the detection of end of fragments in push mode for 2.6.23, could
you try with the latest version ?



Daniel Veillard      | Red Hat
veillard redhat com  | libxml GNOME XML XSLT toolkit | Rpmfind RPM search engine

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]