mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2024-12-28 07:21:26 +03:00
fixing a deallocation problem in xmlRelaxNGParse() in case of errors,
* relaxng.c: fixing a deallocation problem in xmlRelaxNGParse() in case of errors, should fix bug #338306 Daniel
This commit is contained in:
parent
51698c71ef
commit
3f845a99b9
@ -1,3 +1,8 @@
|
||||
Thu Apr 13 09:31:45 CEST 2006 Daniel Veillard <daniel@veillard.com>
|
||||
|
||||
* relaxng.c: fixing a deallocation problem in xmlRelaxNGParse()
|
||||
in case of errors, should fix bug #338306
|
||||
|
||||
Thu Apr 6 10:22:17 CEST 2006 Daniel Veillard <daniel@veillard.com>
|
||||
|
||||
* doc/xmlcatalog.1 doc/xmlcatalog_man.xml doc/xmllint.1 doc/xmllint.xml:
|
||||
|
@ -7394,13 +7394,16 @@ xmlRelaxNGParse(xmlRelaxNGParserCtxtPtr ctxt)
|
||||
if (root == NULL) {
|
||||
xmlRngPErr(ctxt, (xmlNodePtr) doc,
|
||||
XML_RNGP_EMPTY, "xmlRelaxNGParse: %s is empty\n",
|
||||
ctxt->URL, NULL);
|
||||
xmlFreeDoc(doc);
|
||||
(ctxt->URL ? ctxt->URL : "schemas"), NULL);
|
||||
|
||||
xmlFreeDoc(ctxt->document);
|
||||
ctxt->document = NULL;
|
||||
return (NULL);
|
||||
}
|
||||
ret = xmlRelaxNGParseDocument(ctxt, root);
|
||||
if (ret == NULL) {
|
||||
xmlFreeDoc(doc);
|
||||
xmlFreeDoc(ctxt->document);
|
||||
ctxt->document = NULL;
|
||||
return (NULL);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user