summaryrefslogtreecommitdiffstats
path: root/unix/tclUnixThrd.c
diff options
context:
space:
mode:
authorandreask@activestate.com <andreas_kupries>2004-07-15 22:04:26 (GMT)
committerandreask@activestate.com <andreas_kupries>2004-07-15 22:04:26 (GMT)
commit90f5f44f027a70075762ec0c2e041e974d584154 (patch)
treefa0d5dec503d5ebb4bb134774ad9bf18a4e274a5 /unix/tclUnixThrd.c
parent630c714ce6bfceee61c428096ecb9098975f4d02 (diff)
downloadtcl-90f5f44f027a70075762ec0c2e041e974d584154.zip
tcl-90f5f44f027a70075762ec0c2e041e974d584154.tar.gz
tcl-90f5f44f027a70075762ec0c2e041e974d584154.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;
}