diff --git a/xpath.c b/xpath.c index 94815075..b816bd36 100644 --- a/xpath.c +++ b/xpath.c @@ -11932,11 +11932,11 @@ xmlXPathCompOpEvalPositionalPredicate(xmlXPathParserContextPtr ctxt, } } - frame = xmlXPathSetFrame(ctxt); valuePush(ctxt, contextObj); + frame = xmlXPathSetFrame(ctxt); res = xmlXPathCompOpEvalToBoolean(ctxt, exprOp, 1); - tmp = valuePop(ctxt); xmlXPathPopFrame(ctxt, frame); + tmp = valuePop(ctxt); if ((ctxt->error != XPATH_EXPRESSION_OK) || (res == -1)) { while (tmp != contextObj) {