aboutsummaryrefslogtreecommitdiffstats
path: root/xpath.c
diff options
context:
space:
mode:
authorDaniel Veillard <veillard@src.gnome.org>2001-04-18 21:41:07 +0000
committerDaniel Veillard <veillard@src.gnome.org>2001-04-18 21:41:07 +0000
commite470df7fdd3505c6232d6498f3b8834ebfce522d (patch)
treee6c665ce737cd32060f30a6935d2d00f59f58350 /xpath.c
parentceacdd964dd0022ca25077e3e4e52a980a231e23 (diff)
downloadandroid_external_libxml2-e470df7fdd3505c6232d6498f3b8834ebfce522d.tar.gz
android_external_libxml2-e470df7fdd3505c6232d6498f3b8834ebfce522d.tar.bz2
android_external_libxml2-e470df7fdd3505c6232d6498f3b8834ebfce522d.zip
3 hours of debug, this was hell:
- SAX.c parser.c xpath.c: generating IDs when not validating from an external parsed entity was poisoning the ID has table with removed values. This was killing XSLT on the KDE help browser. Daniel
Diffstat (limited to 'xpath.c')
-rw-r--r--xpath.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/xpath.c b/xpath.c
index 48ddc75b..7d4fc328 100644
--- a/xpath.c
+++ b/xpath.c
@@ -3755,7 +3755,10 @@ xmlXPathNextNamespace(xmlXPathParserContextPtr ctxt, xmlNodePtr cur) {
*/
xmlNodePtr
xmlXPathNextAttribute(xmlXPathParserContextPtr ctxt, xmlNodePtr cur) {
- if (ctxt->context->node->type != XML_ELEMENT_NODE) return(NULL);
+ if (ctxt->context->node == NULL)
+ return(NULL);
+ if (ctxt->context->node->type != XML_ELEMENT_NODE)
+ return(NULL);
if (cur == NULL) {
if (ctxt->context->node == (xmlNodePtr) ctxt->context->doc)
return(NULL);