mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-09 16:24:57 +01:00
fix apparent free-ordering issue reported in #7926
This commit is contained in:
parent
12c4a88db6
commit
96daa4036a
1 changed files with 2 additions and 2 deletions
|
|
@ -770,16 +770,16 @@ static XMLSharedNodeList* find_impl(xmlXPathContext* ctxt, const string& xpath)
|
||||||
xmlXPathObject* result = xmlXPathEval((const xmlChar*)xpath.c_str(), ctxt);
|
xmlXPathObject* result = xmlXPathEval((const xmlChar*)xpath.c_str(), ctxt);
|
||||||
|
|
||||||
if (!result) {
|
if (!result) {
|
||||||
xmlXPathFreeContext(ctxt);
|
|
||||||
xmlFreeDoc(ctxt->doc);
|
xmlFreeDoc(ctxt->doc);
|
||||||
|
xmlXPathFreeContext(ctxt);
|
||||||
|
|
||||||
throw XMLException("Invalid XPath: " + xpath);
|
throw XMLException("Invalid XPath: " + xpath);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (result->type != XPATH_NODESET) {
|
if (result->type != XPATH_NODESET) {
|
||||||
xmlXPathFreeObject(result);
|
xmlXPathFreeObject(result);
|
||||||
xmlXPathFreeContext(ctxt);
|
|
||||||
xmlFreeDoc(ctxt->doc);
|
xmlFreeDoc(ctxt->doc);
|
||||||
|
xmlXPathFreeContext(ctxt);
|
||||||
|
|
||||||
throw XMLException("Only nodeset result types are supported.");
|
throw XMLException("Only nodeset result types are supported.");
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue