summaryrefslogtreecommitdiffstats
path: root/unix/tclUnixThrd.c
diff options
context:
space:
mode:
authorandreas_kupries <akupries@shaw.ca>2004-07-15 22:04:42 (GMT)
committerandreas_kupries <akupries@shaw.ca>2004-07-15 22:04:42 (GMT)
commit41c41a5064ca0fd45c653ad74c6bffa38cde6e71 (patch)
treeeb6a1eca096ab1c532d838a3ed6f329d9e153ef2 /unix/tclUnixThrd.c
parent2aebe9b17a5cf409268dbd8af3e7f7c2d1595846 (diff)
downloadtcl-41c41a5064ca0fd45c653ad74c6bffa38cde6e71.zip
tcl-41c41a5064ca0fd45c653ad74c6bffa38cde6e71.tar.gz
tcl-41c41a5064ca0fd45c653ad74c6bffa38cde6e71.tar.bz2
* unix/tclUnixThrd.c (TclpFinalizeMutex): Accepted Joe
Mistachkin's patch for [Tcl SF Bug 99453], closing leakage of mutexes. They were not destroyed properly upon finalization.
Diffstat (limited to 'unix/tclUnixThrd.c')
-rw-r--r--unix/tclUnixThrd.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/unix/tclUnixThrd.c b/unix/tclUnixThrd.c
index ef06dee..edcb0f3 100644
--- a/unix/tclUnixThrd.c
+++ b/unix/tclUnixThrd.c
@@ -542,6 +542,7 @@ TclpFinalizeMutex(mutexPtr)
{
pthread_mutex_t *pmutexPtr = *(pthread_mutex_t **)mutexPtr;
if (pmutexPtr != NULL) {
+ pthread_mutex_destroy(pmutexPtr);
ckfree((char *)pmutexPtr);
*mutexPtr = NULL;
}