From 1a9b7084f6313be41edbe143c1f56f327504d06c Mon Sep 17 00:00:00 2001 From: Daniel Veillard Date: Fri, 2 Jan 2004 10:42:01 +0000 Subject: [PATCH] found and fixed a bug misallocating some non blank text node strings from * SAX2.c: found and fixed a bug misallocating some non blank text node strings from the dictionnary. * xmlmemory.c: fixed a problem with the memory debug mutex release. Daniel --- ChangeLog | 7 +++++++ SAX2.c | 2 +- xmlmemory.c | 1 + 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 363564f2..59cb11c8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +Fri Jan 2 11:40:06 CET 2004 Daniel Veillard + + * SAX2.c: found and fixed a bug misallocating some non + blank text node strings from the dictionnary. + * xmlmemory.c: fixed a problem with the memory debug mutex + release. + Wed Dec 31 22:02:37 HKT 2003 William Brack * xinclude.c: fixed problem caused by wrong dictionary diff --git a/SAX2.c b/SAX2.c index 0ec19ca1..d27d5748 100644 --- a/SAX2.c +++ b/SAX2.c @@ -1670,7 +1670,7 @@ xmlSAX2TextNode(xmlParserCtxtPtr ctxt, const xmlChar *str, int len) { int i; for (i = 1;i < len;i++) { - if (!IS_BLANK_CH(*str)) goto skip; + if (!IS_BLANK_CH(str[i])) goto skip; } intern = xmlDictLookup(ctxt->dict, str, len); } diff --git a/xmlmemory.c b/xmlmemory.c index d8fa2b9c..55831d72 100644 --- a/xmlmemory.c +++ b/xmlmemory.c @@ -822,6 +822,7 @@ xmlCleanupMemory(void) { return; xmlFreeMutex(xmlMemMutex); + xmlMemMutex = NULL; xmlMemInitialized = 0; }