summaryrefslogtreecommitdiffstats
path: root/generic/tclCkalloc.c
diff options
context:
space:
mode:
authormdejong <mdejong>2002-08-01 18:32:53 (GMT)
committermdejong <mdejong>2002-08-01 18:32:53 (GMT)
commit316eec86b0874ec295c586102740591c39da32bf (patch)
treee4241aa1f00dda0dd079a09968b6966ba5dc4878 /generic/tclCkalloc.c
parent8ec3f17d79cc3df7c80743302212dfdfa95f9c50 (diff)
downloadtcl-316eec86b0874ec295c586102740591c39da32bf.zip
tcl-316eec86b0874ec295c586102740591c39da32bf.tar.gz
tcl-316eec86b0874ec295c586102740591c39da32bf.tar.bz2
* generic/tclCkalloc.c (TclFinalizeMemorySubsystem):
Don't lock the ckalloc mutex before invoking the Tcl_DumpActiveMemory function since it also locks the same mutex. This code is only executed when "memory onexit filename" has been executed and Tcl is compiled with -DTCL_MEM_DEBUG.
Diffstat (limited to 'generic/tclCkalloc.c')
-rw-r--r--generic/tclCkalloc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/generic/tclCkalloc.c b/generic/tclCkalloc.c
index 4a6c279..fe90a74 100644
--- a/generic/tclCkalloc.c
+++ b/generic/tclCkalloc.c
@@ -13,7 +13,7 @@
*
* This code contributed by Karl Lehenbauer and Mark Diekhans
*
- * RCS: @(#) $Id: tclCkalloc.c,v 1.16 2002/07/11 13:53:59 dkf Exp $
+ * RCS: @(#) $Id: tclCkalloc.c,v 1.17 2002/08/01 18:32:53 mdejong Exp $
*/
#include "tclInt.h"
@@ -1232,12 +1232,12 @@ void
TclFinalizeMemorySubsystem()
{
#ifdef TCL_MEM_DEBUG
- Tcl_MutexLock(ckallocMutexPtr);
if (tclMemDumpFileName != NULL) {
Tcl_DumpActiveMemory(tclMemDumpFileName);
} else if (onExitMemDumpFileName != NULL) {
Tcl_DumpActiveMemory(onExitMemDumpFileName);
}
+ Tcl_MutexLock(ckallocMutexPtr);
if (curTagPtr != NULL) {
TclpFree((char *) curTagPtr);
curTagPtr = NULL;