[Try #2, seems, like 1st message went to /dev/null instead of mailing list :-( ]
2006-06-26 Andrew W. Nosenko <[EMAIL PROTECTED]>
* threads.c:
(xmlFreeRMutex) [HAVE_PTHREAD_H]:
Destroying of condition, which allocated in the xmlNewRMutex(),
is added.
Absent pthread_cond_destroy() produces memory leak under FreeBSD
(~4 bytes per each xmlNewRMutex() call). Whether memory leaks on the other
systems depends on pthread implementation.
--
Andrew W. Nosenko <[EMAIL PROTECTED]>
2006-06-26 Andrew W. Nosenko <[EMAIL PROTECTED]>
* threads.c:
(xmlFreeRMutex) [HAVE_PTHREAD_H]:
Destroying of condition, which allocated in the xmlNewRMutex(),
is added.
Index: threads.c
===================================================================
RCS file: /cvs/gnome/libxml2/threads.c,v
retrieving revision 1.36
diff -u -p -r1.36 threads.c
--- threads.c 4 Sep 2005 21:39:00 -0000 1.36
+++ threads.c 26 Jun 2006 10:06:51 -0000
@@ -320,7 +320,10 @@ xmlFreeRMutex(xmlRMutexPtr tok ATTRIBUTE
return;
#ifdef HAVE_PTHREAD_H
if (libxml_is_threaded != 0)
+ {
pthread_mutex_destroy(&tok->lock);
+ pthread_cond_destroy(&tok->cv);
+ }
#elif defined HAVE_WIN32_THREADS
DeleteCriticalSection(&tok->cs);
#elif defined HAVE_BEOS_THREADS
_______________________________________________
xml mailing list, project page http://xmlsoft.org/
[email protected]
http://mail.gnome.org/mailman/listinfo/xml