From 8142202cc68380b20fde7dc42bdb7a79003b162b Mon Sep 17 00:00:00 2001 From: Packit Date: Aug 25 2020 09:22:20 +0000 Subject: Apply patch libxml2-CVE-2018-14404.patch patch_name: libxml2-CVE-2018-14404.patch location_in_specfile: 7 present_in_specfile: true --- diff --git a/xpath.c b/xpath.c index 3527473..3fcdc9e 100644 --- a/xpath.c +++ b/xpath.c @@ -13337,9 +13337,8 @@ xmlXPathCompOpEval(xmlXPathParserContextPtr ctxt, xmlXPathStepOpPtr op) return(0); } xmlXPathBooleanFunction(ctxt, 1); - arg1 = valuePop(ctxt); - arg1->boolval &= arg2->boolval; - valuePush(ctxt, arg1); + if (ctxt->value != NULL) + ctxt->value->boolval &= arg2->boolval; xmlXPathReleaseObject(ctxt->context, arg2); return (total); case XPATH_OP_OR: @@ -13363,9 +13362,8 @@ xmlXPathCompOpEval(xmlXPathParserContextPtr ctxt, xmlXPathStepOpPtr op) return(0); } xmlXPathBooleanFunction(ctxt, 1); - arg1 = valuePop(ctxt); - arg1->boolval |= arg2->boolval; - valuePush(ctxt, arg1); + if (ctxt->value != NULL) + ctxt->value->boolval |= arg2->boolval; xmlXPathReleaseObject(ctxt->context, arg2); return (total); case XPATH_OP_EQUAL: