summaryrefslogtreecommitdiffstats
path: root/generic/tclAlloc.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2018-05-17 18:53:29 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2018-05-17 18:53:29 (GMT)
commit4f1ea4779be85d8837f3a133b52d3b5aa9e53fda (patch)
tree401339ab1470b40cccd1bec272ac42427c694d92 /generic/tclAlloc.c
parent4e12ee1bc4fe5d4c49f614f7e18c6df1c8ea0e40 (diff)
parentf44e7c1795fe27f3f37e692f275545e3fe73ebd6 (diff)
downloadtcl-4f1ea4779be85d8837f3a133b52d3b5aa9e53fda.zip
tcl-4f1ea4779be85d8837f3a133b52d3b5aa9e53fda.tar.gz
tcl-4f1ea4779be85d8837f3a133b52d3b5aa9e53fda.tar.bz2
TIP #491 implementation: Threading Support: phasing out non-threaded builds
Diffstat (limited to 'generic/tclAlloc.c')
-rw-r--r--generic/tclAlloc.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/generic/tclAlloc.c b/generic/tclAlloc.c
index 8a4b1c8..e04e9c6 100644
--- a/generic/tclAlloc.c
+++ b/generic/tclAlloc.c
@@ -22,7 +22,7 @@
*/
#include "tclInt.h"
-#if !defined(TCL_THREADS) || !defined(USE_THREAD_ALLOC)
+#if (defined(TCL_THREADS) && !TCL_THREADS) || !defined(USE_THREAD_ALLOC)
#if USE_TCLALLOC
@@ -121,7 +121,7 @@ static struct block bigBlocks={ /* Big blocks aren't suballocated. */
* variable.
*/
-#ifdef TCL_THREADS
+#if !defined(TCL_THREADS) || TCL_THREADS
static Tcl_Mutex *allocMutexPtr;
#endif
static int allocInit = 0;
@@ -171,7 +171,7 @@ TclInitAlloc(void)
{
if (!allocInit) {
allocInit = 1;
-#ifdef TCL_THREADS
+#if !defined(TCL_THREADS) || TCL_THREADS
allocMutexPtr = Tcl_GetAllocMutex();
#endif
}