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
diff --git a/xpath.c b/xpath.c
index 48ddc75..7d4fc32 100644
--- a/xpath.c
+++ b/xpath.c
@@ -3755,7 +3755,10 @@
*/
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);