summaryrefslogtreecommitdiffstats
path: root/unix/tclUnixThrd.c
diff options
context:
space:
mode:
authorandreas_kupries <akupries@shaw.ca>2004-07-15 22:04:26 (GMT)
committerandreas_kupries <akupries@shaw.ca>2004-07-15 22:04:26 (GMT)
commit67b7d85c2dd267ed4ea308956907a48a2d186cca (patch)
treefa0d5dec503d5ebb4bb134774ad9bf18a4e274a5 /unix/tclUnixThrd.c
parentf1672e88f2ba0cd791ed0ef2b4196696cf993c5c (diff)
downloadtcl-67b7d85c2dd267ed4ea308956907a48a2d186cca.zip
tcl-67b7d85c2dd267ed4ea308956907a48a2d186cca.tar.gz
tcl-67b7d85c2dd267ed4ea308956907a48a2d186cca.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 78ca385..d300d34 100644
--- a/unix/tclUnixThrd.c
+++ b/unix/tclUnixThrd.c
@@ -494,6 +494,7 @@ TclpFinalizeMutex(mutexPtr)
{
pthread_mutex_t *pmutexPtr = *(pthread_mutex_t **)mutexPtr;
if (pmutexPtr != NULL) {
+ pthread_mutex_destroy(pmutexPtr);
ckfree((char *)pmutexPtr);
*mutexPtr = NULL;
}