From 72ee48d55f9002544d011826e2897b5054b7e32c Mon Sep 17 00:00:00 2001 From: "William M. Brack" Date: Tue, 30 Dec 2003 08:30:19 +0000 Subject: Fixed memory leak reported by Dave Beckett Removed spurious comment * parser.c, xmlmemory.c, include/libxml/xmlmemory.h: Fixed memory leak reported by Dave Beckett * xmlschemas.c: Removed spurious comment reported on the mailing list * xinclude.c, xpath.c, xpointer.c, libxml/include/xpointer.h: Further work on Bug 129967 concerning xpointer range handling and range-to function; much better, but still not complete --- xmlmemory.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'xmlmemory.c') diff --git a/xmlmemory.c b/xmlmemory.c index 712a967f..d8fa2b9c 100644 --- a/xmlmemory.c +++ b/xmlmemory.c @@ -811,6 +811,20 @@ xmlInitMemory(void) return(0); } +/** + * xmlCleanupMemory: + * + * Free up all the memory associated with memorys + */ +void +xmlCleanupMemory(void) { + if (xmlMemInitialized == 0) + return; + + xmlFreeMutex(xmlMemMutex); + xmlMemInitialized = 0; +} + /** * xmlMemSetup: * @freeFunc: the free() function to use -- cgit v1.2.1