Re: [xml] xmlGetLineNo() always returns 0 for XML_TEXT_NODE
- From: Daniel Veillard <veillard redhat com>
- To: Ralf Junker <ralfjunker gmx de>
- Cc: xml gnome org
- Subject: Re: [xml] xmlGetLineNo() always returns 0 for XML_TEXT_NODE
- Date: Mon, 7 Jul 2008 09:53:22 -0400
On Mon, Jul 07, 2008 at 02:57:25PM +0200, Ralf Junker wrote:
Daniel Veillard wrote:
This may depend on the API used, i.e. whether you're on SAX1 or SAX2 underneath.
I am using xmlReadFile(), which is supposed to use SAX2 underneath (if I am not mistaken).
yes, that's the new APIs, good :-)
It seems xmlSAX2TextNode() forgets to set the line, can you check the
enclosed patch fixes it for you ?
Yes, the patch appears to work well. It makes xmlGetLineNo() return proper line numbers for XML_TEXT_NODE
nodes where it returns just 0 (zero) without the patch.
okay, commited to SVN rev 3751
thanks !
Daniel
--
Red Hat Virtualization group http://redhat.com/virtualization/
Daniel Veillard | virtualization library http://libvirt.org/
veillard redhat com | libxml GNOME XML XSLT toolkit http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]