From 24d85de726b573fecae24d402366b2fe7237af11 Mon Sep 17 00:00:00 2001 From: "William M. Brack" Date: Thu, 23 Oct 2003 08:49:52 +0000 Subject: [PATCH] Fixed problem with cascaded predicates (more of bug 119946) * libxslt/pattern.c: Fixed problem with cascaded predicates (more of bug 119946) --- ChangeLog | 5 +++++ libxslt/pattern.c | 6 +++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 637f482..8c27dea 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Thu Oct 23 15:48:39 HKT 2003 William Brack + + * libxslt/pattern.c: Fixed problem with cascaded predicates + (more of bug 119946) + Thu Oct 23 15:37:26 HKT 2003 William Brack * restored earliest portion of ChangeLog (was corrupted) diff --git a/libxslt/pattern.c b/libxslt/pattern.c index 404c22f..fa518da 100644 --- a/libxslt/pattern.c +++ b/libxslt/pattern.c @@ -656,7 +656,8 @@ xsltTestCompMatch(xsltTransformContextPtr ctxt, xsltCompMatchPtr comp, xmlXPathFreeObject(newlist); return(-1); } - + index = 0; + if ((parent == NULL) || (node->doc == NULL)) nocache = 1; else { @@ -666,6 +667,7 @@ xsltTestCompMatch(xsltTransformContextPtr ctxt, xsltCompMatchPtr comp, BAD_CAST " fake node libxslt"))) nocache = 1; } + if (nocache == 0) { if (list != NULL) xmlXPathFreeObject(list); @@ -675,6 +677,8 @@ xsltTestCompMatch(xsltTransformContextPtr ctxt, xsltCompMatchPtr comp, (void *) list; XSLT_RUNTIME_EXTRA(ctxt, select->previousExtra) = (void *) doc; + XSLT_RUNTIME_EXTRA(ctxt, select->indexExtra) = + 0; XSLT_RUNTIME_EXTRA_FREE(ctxt, select->lenExtra) = (xmlFreeFunc) xmlXPathFreeObject; } else -- 2.7.4