[libxml2] Make "xmllint --push --recovery" work



commit 2b4769a6bd1d6a568fa067f21ff6f96700936642
Author: Nick Wellnhofer <wellnhofer aevum de>
Date:   Sun Aug 16 22:02:04 2020 +0200

    Make "xmllint --push --recovery" work

 xmllint.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/xmllint.c b/xmllint.c
index c647486f3..4469bf0a5 100644
--- a/xmllint.c
+++ b/xmllint.c
@@ -2287,7 +2287,7 @@ static void parseAndPrintFile(char *filename, xmlParserCtxtPtr rectxt) {
                    doc = ctxt->myDoc;
                    ret = ctxt->wellFormed;
                    xmlFreeParserCtxt(ctxt);
-                   if (!ret) {
+                   if ((!ret) && (!recovery)) {
                        xmlFreeDoc(doc);
                        doc = NULL;
                    }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]