summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNick Wellnhofer <wellnhofer@aevum.de>2017-05-25 01:21:57 +0200
committerNick Wellnhofer <wellnhofer@aevum.de>2018-04-16 18:28:42 +0200
commit938835e763277684274ac31afc08fc40fa419aae (patch)
treeb63d44be45a682552b3020a149b64a1f2e7a589d
parente22a83b1d095dac25ce05e1a2d9f263f41d11c68 (diff)
downloadlibxml2-938835e763277684274ac31afc08fc40fa419aae.tar.gz
Don't change context node in xmlXPathRoot
-rw-r--r--xpath.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/xpath.c b/xpath.c
index 601763ee..1e98ddc2 100644
--- a/xpath.c
+++ b/xpath.c
@@ -8477,9 +8477,8 @@ void
xmlXPathRoot(xmlXPathParserContextPtr ctxt) {
if ((ctxt == NULL) || (ctxt->context == NULL))
return;
- ctxt->context->node = (xmlNodePtr) ctxt->context->doc;
valuePush(ctxt, xmlXPathCacheNewNodeSet(ctxt->context,
- ctxt->context->node));
+ (xmlNodePtr) ctxt->context->doc));
}
/************************************************************************