Re: [xml] Bug in xpath.c
- From: Daniel Veillard <veillard redhat com>
- To: François Delyon <f delyon satimage fr>
- Cc: xml gnome org
- Subject: Re: [xml] Bug in xpath.c
- Date: Thu, 16 Nov 2006 09:58:16 -0500
On Thu, Nov 16, 2006 at 03:45:25PM +0100, François Delyon wrote:
Noticed in xmlXPathNextDescendantOrSelfElemParent:
#ifdef LIBXML_DOCB_ENABLED
/* Not sure if we need those here. */
case XML_DOCUMENT_NODE:
case XML_DOCB_DOCUMENT_NODE:
#endif
case XML_HTML_DOCUMENT_NODE:
This makes xpath requests like "//a" to fail under some circumstances
when LIBXML_DOCB_ENABLED is 0.
I guess that the intent of the writer was:
case XML_DOCUMENT_NODE:
#ifdef LIBXML_DOCB_ENABLED
case XML_DOCB_DOCUMENT_NODE:
#endif
case XML_HTML_DOCUMENT_NODE:
That was already fixed in CVS, as William Brack spotted the problem
3 weeks ago:
phio:~/XML -> cvs -z9 diff -r LIBXML2_2_6_27 xpath.c
Index: xpath.c
===================================================================
RCS file: /cvs/gnome/gnome-xml/xpath.c,v
retrieving revision 1.325
retrieving revision 1.326
diff -u -r1.325 -r1.326
--- xpath.c 17 Oct 2006 19:39:33 -0000 1.325
+++ xpath.c 26 Oct 2006 08:55:47 -0000 1.326
@@ -7668,9 +7668,9 @@
continue;
}
break;
-#ifdef LIBXML_DOCB_ENABLED
/* Not sure if we need those here. */
case XML_DOCUMENT_NODE:
+#ifdef LIBXML_DOCB_ENABLED
case XML_DOCB_DOCUMENT_NODE:
#endif
case XML_HTML_DOCUMENT_NODE:
paphio:~/XML ->
That's why I could not reproduce the problem !
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]