change a small bit in the way valididy error messages get initialized
* parserInternals.c: change a small bit in the way valididy
error messages get initialized
* python/TODO python/libxml.c python/libxml2-python-api.xml
python/libxml2class.txt python/libxml_wrap.h python/types.c:
added some memory debugging to track leaks at the libxml2 level
* python/tests/*.py: changed all tests to check for leaks,
there is just one left in XPath extension registrations.
daniel
diff --git a/parserInternals.c b/parserInternals.c
index b8bdaa9..91eeae1 100644
--- a/parserInternals.c
+++ b/parserInternals.c
@@ -2257,16 +2257,14 @@
sax->ignorableWhitespace = ignorableWhitespace;
ctxt->vctxt.userData = ctxt;
+ ctxt->vctxt.error = xmlParserValidityError;
+ ctxt->vctxt.warning = xmlParserValidityWarning;
if (ctxt->validate) {
- ctxt->vctxt.error = xmlParserValidityError;
if (xmlGetWarningsDefaultValue == 0)
ctxt->vctxt.warning = NULL;
else
ctxt->vctxt.warning = xmlParserValidityWarning;
ctxt->vctxt.nodeMax = 0;
- } else {
- ctxt->vctxt.error = NULL;
- ctxt->vctxt.warning = NULL;
}
ctxt->replaceEntities = xmlSubstituteEntitiesDefaultValue;
ctxt->record_info = 0;