summaryrefslogtreecommitdiff
path: root/parserInternals.c
diff options
context:
space:
mode:
authorDaniel Veillard <veillard@src.gnome.org>2003-10-02 22:28:19 +0000
committerDaniel Veillard <veillard@src.gnome.org>2003-10-02 22:28:19 +0000
commit2b8c4a151bb6bf91c10541b0593218bca5b3d5ce (patch)
treeba95f7861f9d565c747ee7bc752ca711fc35cd8a /parserInternals.c
parente7acf431b8fd60e98cb00d52ba071f1be8cbfbd1 (diff)
downloadlibxml2-2b8c4a151bb6bf91c10541b0593218bca5b3d5ce.tar.gz
changed 'make tests' to use a concise output, scrolling to see where thing
* Makefile.am: changed 'make tests' to use a concise output, scrolling to see where thing broke wasn't pleasant * configure.in: some beta4 preparation, but not ready yet * error.c globals.c include/libxml/globals.h include/libxml/xmlerror.h: new error handling code, last error informations are stored in the parsing context or a global variable, new APIs to handle the xmlErrorPtr type. * parser.c parserInternals.c valid.c : started migrating to the new error handling code, it's a royal pain. * include/libxml/parser.h include/libxml/parserInternals.h: moved the definition of xmlNewParserCtxt() * parser.c: small potential buffer access problem in push code provided by Justin Fletcher * result/*.sax result/VC/PENesting* result/namespaces/* result/valid/*.err: some error messages were sligthly changed. Daniel
Diffstat (limited to 'parserInternals.c')
-rw-r--r--parserInternals.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/parserInternals.c b/parserInternals.c
index 7b2270c1..8966d8ad 100644
--- a/parserInternals.c
+++ b/parserInternals.c
@@ -2123,6 +2123,19 @@ xmlFreeParserCtxt(xmlParserCtxtPtr ctxt)
cur = next;
}
}
+ /*
+ * cleanup the error strings
+ */
+ if (ctxt->lastError.message != NULL)
+ xmlFree(ctxt->lastError.message);
+ if (ctxt->lastError.file != NULL)
+ xmlFree(ctxt->lastError.file);
+ if (ctxt->lastError.str1 != NULL)
+ xmlFree(ctxt->lastError.str1);
+ if (ctxt->lastError.str2 != NULL)
+ xmlFree(ctxt->lastError.str2);
+ if (ctxt->lastError.str3 != NULL)
+ xmlFree(ctxt->lastError.str3);
#ifdef LIBXML_CATALOG_ENABLED
if (ctxt->catalogs != NULL)