From b506f6289f0b2d01d9891ece0a217f4cd45224d8 Mon Sep 17 00:00:00 2001 From: stanton Date: Thu, 10 Dec 1998 21:21:26 +0000 Subject: * Fixed lots of files that used TCL_THREAD instead of TCL_THREADS. * generic/tclEncoding.c (Tcl_FreeEncoding): Moved most of the code into a static FreeEncoding routine that does not grab the encodingMutex to avoid deadlocks/races when called from other routines that already have the mutex. --- ChangeLog | 9 +++++++++ doc/http.n | 6 ++++-- generic/tclAsync.c | 4 ++-- generic/tclBasic.c | 4 ++-- generic/tclClock.c | 4 ++-- generic/tclCompExpr.c | 4 ++-- generic/tclCompile.c | 4 ++-- generic/tclEncoding.c | 45 ++++++++++++++++++++++++++++++++------------- generic/tclEnv.c | 4 ++-- generic/tclEvent.c | 4 ++-- generic/tclExecute.c | 4 ++-- generic/tclFileName.c | 4 ++-- generic/tclIOUtil.c | 4 ++-- generic/tclInterp.c | 4 ++-- generic/tclLoad.c | 4 ++-- generic/tclNamesp.c | 4 ++-- generic/tclNotify.c | 4 ++-- generic/tclObj.c | 6 +++--- generic/tclPipe.c | 4 ++-- generic/tclPreserve.c | 4 ++-- generic/tclUtil.c | 4 ++-- unix/tclUnixNotfy.c | 4 ++-- unix/tclUnixSock.c | 4 ++-- unix/tclUnixTime.c | 4 ++-- 24 files changed, 88 insertions(+), 58 deletions(-) diff --git a/ChangeLog b/ChangeLog index 753abc8..40a7874 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +1998-12-10 + + * Fixed lots of files that used TCL_THREAD instead of TCL_THREADS. + + * generic/tclEncoding.c (Tcl_FreeEncoding): Moved most of the code + into a static FreeEncoding routine that does not grab the + encodingMutex to avoid deadlocks/races when called from other + routines that already have the mutex. + 1998-12-09 * library/msgcat1.0/msgcat.tcl: Fixed bad export list, fixed so diff --git a/doc/http.n b/doc/http.n index 71065dc..2d6cf16 100644 --- a/doc/http.n +++ b/doc/http.n @@ -4,7 +4,7 @@ '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. '\" -'\" RCS: @(#) $Id: http.n,v 1.1.2.1 1998/09/24 23:58:32 stanton Exp $ +'\" RCS: @(#) $Id: http.n,v 1.1.2.2 1998/12/10 21:21:28 stanton Exp $ '\" .so man.macros .TH "Http" n 8.0 Tcl "Tcl Built-In Commands" @@ -250,7 +250,9 @@ Use this construct to create an easy-to-use array variable: .CS upvar #0 $token state .CE -The following elements of the array are supported: +Once the data associated with the url is no longer needed, the state +array should be unset to free up storage. The following elements of +the array are supported: .RS .TP \fBbody\fR diff --git a/generic/tclAsync.c b/generic/tclAsync.c index 8f04d67..f38232f 100644 --- a/generic/tclAsync.c +++ b/generic/tclAsync.c @@ -12,7 +12,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclAsync.c,v 1.1.2.3 1998/11/11 04:54:06 stanton Exp $ + * RCS: @(#) $Id: tclAsync.c,v 1.1.2.4 1998/12/10 21:21:30 stanton Exp $ */ #include "tclInt.h" @@ -42,7 +42,7 @@ static AsyncHandler *firstHandler; /* First handler defined for process, * or NULL if none. */ static AsyncHandler *lastHandler; /* Last handler or NULL. */ -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex asyncMutex; /* Process-wide async handler lock */ #endif diff --git a/generic/tclBasic.c b/generic/tclBasic.c index f1c0fbd..41525bf 100644 --- a/generic/tclBasic.c +++ b/generic/tclBasic.c @@ -12,7 +12,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclBasic.c,v 1.1.2.5 1998/11/11 04:54:07 stanton Exp $ + * RCS: @(#) $Id: tclBasic.c,v 1.1.2.6 1998/12/10 21:21:31 stanton Exp $ */ #include "tclInt.h" @@ -599,7 +599,7 @@ Tcl_CallWhenDeleted(interp, proc, clientData) { Interp *iPtr = (Interp *) interp; static int assocDataCounter = 0; -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex assocMutex; #endif int new; diff --git a/generic/tclClock.c b/generic/tclClock.c index 0faef9d..34561a5 100644 --- a/generic/tclClock.c +++ b/generic/tclClock.c @@ -11,7 +11,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclClock.c,v 1.1.2.3 1998/11/11 04:54:07 stanton Exp $ + * RCS: @(#) $Id: tclClock.c,v 1.1.2.4 1998/12/10 21:21:34 stanton Exp $ */ #include "tcl.h" @@ -22,7 +22,7 @@ * The date parsing stuff uses lexx and has tons o statics. */ -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex clockMutex; #endif diff --git a/generic/tclCompExpr.c b/generic/tclCompExpr.c index 8843ec3..ba1764a 100644 --- a/generic/tclCompExpr.c +++ b/generic/tclCompExpr.c @@ -8,7 +8,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclCompExpr.c,v 1.1.2.5 1998/12/09 01:14:10 stanton Exp $ + * RCS: @(#) $Id: tclCompExpr.c,v 1.1.2.6 1998/12/10 21:21:36 stanton Exp $ */ #include "tclInt.h" @@ -109,7 +109,7 @@ typedef struct ExprInfo { static int opTableInitialized = 0; /* 0 means not yet initialized. */ -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex opMutex; #endif diff --git a/generic/tclCompile.c b/generic/tclCompile.c index 9d229fb..39a8be4 100644 --- a/generic/tclCompile.c +++ b/generic/tclCompile.c @@ -10,7 +10,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclCompile.c,v 1.1.2.6 1998/11/11 04:54:09 stanton Exp $ + * RCS: @(#) $Id: tclCompile.c,v 1.1.2.7 1998/12/10 21:21:37 stanton Exp $ */ #include "tclInt.h" @@ -23,7 +23,7 @@ static Tcl_HashTable auxDataTypeTable; static int auxDataTypeTableInitialized; /* 0 means not yet initialized. */ -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex tableMutex; #endif diff --git a/generic/tclEncoding.c b/generic/tclEncoding.c index 8e4f539..fca0661 100644 --- a/generic/tclEncoding.c +++ b/generic/tclEncoding.c @@ -8,7 +8,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclEncoding.c,v 1.1.2.4 1998/11/11 04:54:12 stanton Exp $ + * RCS: @(#) $Id: tclEncoding.c,v 1.1.2.5 1998/12/10 21:21:41 stanton Exp $ */ #include "tclInt.h" @@ -141,7 +141,7 @@ typedef struct EscapeEncodingData { */ static Tcl_HashTable encodingTable; -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex encodingMutex; #endif @@ -181,6 +181,7 @@ static int EscapeToUtfProc _ANSI_ARGS_((ClientData clientData, Tcl_EncodingState *statePtr, char *dst, int dstLen, int *srcReadPtr, int *dstWrotePtr, int *dstCharsPtr)); +static void FreeEncoding _ANSI_ARGS_((Tcl_Encoding encoding)); static Encoding * GetTableEncoding _ANSI_ARGS_(( EscapeEncodingData *dataPtr, int state)); static Tcl_Encoding LoadEncodingFile _ANSI_ARGS_((Tcl_Interp *interp, @@ -392,13 +393,39 @@ void Tcl_FreeEncoding(encoding) Tcl_Encoding encoding; { + Tcl_MutexLock(&encodingMutex); + FreeEncoding(encoding); + Tcl_MutexUnlock(&encodingMutex); +} + +/* + *---------------------------------------------------------------------- + * + * FreeEncoding -- + * + * This procedure is called to release an encoding by procedures + * that already have the encodingMutex. + * + * Results: + * None. + * + * Side effects: + * The reference count associated with the encoding is decremented + * and the encoding may be deleted if nothing is using it anymore. + * + *---------------------------------------------------------------------- + */ + +static void +FreeEncoding(encoding) + Tcl_Encoding encoding; +{ Encoding *encodingPtr; encodingPtr = (Encoding *) encoding; if (encodingPtr == NULL) { return; } - Tcl_MutexLock(&encodingMutex); encodingPtr->refCount--; if (encodingPtr->refCount == 0) { if (encodingPtr->freeProc != NULL) { @@ -410,7 +437,6 @@ Tcl_FreeEncoding(encoding) ckfree((char *) encodingPtr->name); ckfree((char *) encodingPtr); } - Tcl_MutexUnlock(&encodingMutex); } /* @@ -599,7 +625,7 @@ Tcl_SetSystemEncoding(interp, name) } Tcl_MutexLock(&encodingMutex); - Tcl_FreeEncoding(systemEncoding); + FreeEncoding(systemEncoding); systemEncoding = encoding; Tcl_MutexUnlock(&encodingMutex); @@ -2458,14 +2484,7 @@ EscapeFreeProc(clientData) } subTablePtr = dataPtr->subTables; for (i = 0; i < dataPtr->numSubTables; i++) { - /* - * This is unlocked to avoid deadlock. There is surely an - * obscure race by doing this, except that encodings are - * really only freed during finalization and by the test suite. - */ - Tcl_MutexUnlock(&encodingMutex); - Tcl_FreeEncoding((Tcl_Encoding) subTablePtr->encodingPtr); - Tcl_MutexLock(&encodingMutex); + FreeEncoding((Tcl_Encoding) subTablePtr->encodingPtr); subTablePtr++; } ckfree((char *) dataPtr); diff --git a/generic/tclEnv.c b/generic/tclEnv.c index b73954d..9c8cb00 100644 --- a/generic/tclEnv.c +++ b/generic/tclEnv.c @@ -12,13 +12,13 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclEnv.c,v 1.1.2.3 1998/11/11 04:54:13 stanton Exp $ + * RCS: @(#) $Id: tclEnv.c,v 1.1.2.4 1998/12/10 21:21:42 stanton Exp $ */ #include "tclInt.h" #include "tclPort.h" -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex envMutex; /* To serialize access to environ */ #endif diff --git a/generic/tclEvent.c b/generic/tclEvent.c index 6c170bd..438db04 100644 --- a/generic/tclEvent.c +++ b/generic/tclEvent.c @@ -11,7 +11,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclEvent.c,v 1.1.2.4 1998/11/11 04:54:13 stanton Exp $ + * RCS: @(#) $Id: tclEvent.c,v 1.1.2.5 1998/12/10 21:21:43 stanton Exp $ */ #include "tclInt.h" @@ -76,7 +76,7 @@ typedef struct ExitHandler { static ExitHandler *firstExitPtr = NULL; /* First in list of all exit handlers for * application. */ -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex exitMutex; #endif diff --git a/generic/tclExecute.c b/generic/tclExecute.c index 2f3cc56..484e46c 100644 --- a/generic/tclExecute.c +++ b/generic/tclExecute.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclExecute.c,v 1.1.2.5 1998/12/02 20:08:04 welch Exp $ + * RCS: @(#) $Id: tclExecute.c,v 1.1.2.6 1998/12/10 21:21:43 stanton Exp $ */ #include "tclInt.h" @@ -48,7 +48,7 @@ int errno; */ static int execInitialized = 0; -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex execMutex; #endif diff --git a/generic/tclFileName.c b/generic/tclFileName.c index 6366bdf..28c32b4 100644 --- a/generic/tclFileName.c +++ b/generic/tclFileName.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclFileName.c,v 1.1.2.5 1998/11/11 04:54:15 stanton Exp $ + * RCS: @(#) $Id: tclFileName.c,v 1.1.2.6 1998/12/10 21:21:46 stanton Exp $ */ #include "tclInt.h" @@ -46,7 +46,7 @@ static int initialized = 0; static Tcl_Obj *winRootPatternPtr = NULL; static Tcl_Obj *macRootPatternPtr = NULL; -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex nameMutex; #endif diff --git a/generic/tclIOUtil.c b/generic/tclIOUtil.c index 0701cde..2bfd588 100644 --- a/generic/tclIOUtil.c +++ b/generic/tclIOUtil.c @@ -13,7 +13,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclIOUtil.c,v 1.1.2.5 1998/11/11 04:54:15 stanton Exp $ + * RCS: @(#) $Id: tclIOUtil.c,v 1.1.2.6 1998/12/10 21:21:47 stanton Exp $ */ #include "tclInt.h" @@ -75,7 +75,7 @@ static OpenFileChannelProc defaultOpenFileChannelProc = { static OpenFileChannelProc *openFileChannelProcList = &defaultOpenFileChannelProc; -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex hookMutex; #endif diff --git a/generic/tclInterp.c b/generic/tclInterp.c index 98cd807..00e5d3c 100644 --- a/generic/tclInterp.c +++ b/generic/tclInterp.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclInterp.c,v 1.1.2.4 1998/11/11 04:54:15 stanton Exp $ + * RCS: @(#) $Id: tclInterp.c,v 1.1.2.5 1998/12/10 21:21:48 stanton Exp $ */ #include @@ -21,7 +21,7 @@ */ static int aliasCounter = 0; -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex cntMutex; #endif diff --git a/generic/tclLoad.c b/generic/tclLoad.c index 5678976..b11b74e 100644 --- a/generic/tclLoad.c +++ b/generic/tclLoad.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclLoad.c,v 1.1.2.2 1998/09/24 23:58:55 stanton Exp $ + * RCS: @(#) $Id: tclLoad.c,v 1.1.2.3 1998/12/10 21:21:49 stanton Exp $ */ #include "tclInt.h" @@ -53,7 +53,7 @@ typedef struct LoadedPackage { } LoadedPackage; /* - * TCL_THREAD + * TCL_THREADS * There is a global list of packages that is anchored at firstPackagePtr. * Access to this list is governed by a mutex. */ diff --git a/generic/tclNamesp.c b/generic/tclNamesp.c index 2aee8a4..038bac5 100644 --- a/generic/tclNamesp.c +++ b/generic/tclNamesp.c @@ -19,7 +19,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclNamesp.c,v 1.1.2.3 1998/11/11 04:54:16 stanton Exp $ + * RCS: @(#) $Id: tclNamesp.c,v 1.1.2.4 1998/12/10 21:21:50 stanton Exp $ */ #include "tclInt.h" @@ -46,7 +46,7 @@ */ static long numNsCreated = 0; -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex nsMutex; #endif diff --git a/generic/tclNotify.c b/generic/tclNotify.c index a103f5d..0a8bd28 100644 --- a/generic/tclNotify.c +++ b/generic/tclNotify.c @@ -13,7 +13,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclNotify.c,v 1.1.2.4 1998/11/11 04:54:17 stanton Exp $ + * RCS: @(#) $Id: tclNotify.c,v 1.1.2.5 1998/12/10 21:21:52 stanton Exp $ */ #include "tclInt.h" @@ -80,7 +80,7 @@ static Tcl_ThreadDataKey dataKey; */ static ThreadSpecificData *firstNotifierPtr; -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex listLock; #endif diff --git a/generic/tclObj.c b/generic/tclObj.c index 834b681..aec0b00 100644 --- a/generic/tclObj.c +++ b/generic/tclObj.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclObj.c,v 1.1.2.4 1998/11/11 04:54:17 stanton Exp $ + * RCS: @(#) $Id: tclObj.c,v 1.1.2.5 1998/12/10 21:21:52 stanton Exp $ */ #include "tclInt.h" @@ -21,7 +21,7 @@ static Tcl_HashTable typeTable; static int typeTableInitialized = 0; /* 0 means not yet initialized. */ -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex tableMutex; #endif @@ -36,7 +36,7 @@ Tcl_Obj *tclFreeObjList = NULL; * by the TclNewObj macro, however, so must be visible. */ -#ifdef TCL_THREAD +#ifdef TCL_THREADS Tcl_Mutex tclObjMutex; #endif diff --git a/generic/tclPipe.c b/generic/tclPipe.c index d8550df..4209c46 100644 --- a/generic/tclPipe.c +++ b/generic/tclPipe.c @@ -10,7 +10,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclPipe.c,v 1.1.2.3 1998/11/11 04:54:18 stanton Exp $ + * RCS: @(#) $Id: tclPipe.c,v 1.1.2.4 1998/12/10 21:21:53 stanton Exp $ */ #include "tclInt.h" @@ -32,7 +32,7 @@ typedef struct Detached { } Detached; static Detached *detList = NULL; /* List of all detached proceses. */ -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex pipeMutex; /* Guard access to detList. */ #endif diff --git a/generic/tclPreserve.c b/generic/tclPreserve.c index 26c9031..aac6797 100644 --- a/generic/tclPreserve.c +++ b/generic/tclPreserve.c @@ -12,7 +12,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclPreserve.c,v 1.1.2.3 1998/11/11 04:54:19 stanton Exp $ + * RCS: @(#) $Id: tclPreserve.c,v 1.1.2.4 1998/12/10 21:21:54 stanton Exp $ */ #include "tclInt.h" @@ -40,7 +40,7 @@ static int spaceAvl = 0; /* Total number of structures available static int inUse = 0; /* Count of structures currently in use * in refArray. */ #define INITIAL_SIZE 2 -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex preserveMutex; /* To protect the above statics */ #endif diff --git a/generic/tclUtil.c b/generic/tclUtil.c index 7711321..105d19c 100644 --- a/generic/tclUtil.c +++ b/generic/tclUtil.c @@ -10,7 +10,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclUtil.c,v 1.1.2.4 1998/12/03 23:59:33 stanton Exp $ + * RCS: @(#) $Id: tclUtil.c,v 1.1.2.5 1998/12/10 21:21:55 stanton Exp $ */ #include "tclInt.h" @@ -59,7 +59,7 @@ static char precisionString[10] = "12"; static char precisionFormat[10] = "%.12g"; /* The format string actually used in calls * to sprintf. */ -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex precisionMutex; #endif diff --git a/unix/tclUnixNotfy.c b/unix/tclUnixNotfy.c index 398af41..9acec65 100644 --- a/unix/tclUnixNotfy.c +++ b/unix/tclUnixNotfy.c @@ -11,7 +11,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclUnixNotfy.c,v 1.1.2.4 1998/12/01 05:01:03 stanton Exp $ + * RCS: @(#) $Id: tclUnixNotfy.c,v 1.1.2.5 1998/12/10 21:21:56 stanton Exp $ */ #include "tclInt.h" @@ -169,7 +169,7 @@ static Tcl_ThreadId notifierThread; * Static routines defined in this file. */ -#ifdef TCL_THREAD +#ifdef TCL_THREADS static void NotifierThreadProc _ANSI_ARGS_((ClientData clientData)); #endif static int FileHandlerEventProc _ANSI_ARGS_((Tcl_Event *evPtr, diff --git a/unix/tclUnixSock.c b/unix/tclUnixSock.c index 96b2397..6c1ef03 100644 --- a/unix/tclUnixSock.c +++ b/unix/tclUnixSock.c @@ -8,7 +8,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclUnixSock.c,v 1.1.2.3 1998/11/11 04:54:22 stanton Exp $ + * RCS: @(#) $Id: tclUnixSock.c,v 1.1.2.4 1998/12/10 21:21:58 stanton Exp $ */ #include "tcl.h" @@ -41,7 +41,7 @@ static char hostname[TCL_HOSTNAME_LEN + 1]; static int hostnameInited = 0; -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex hostMutex; #endif diff --git a/unix/tclUnixTime.c b/unix/tclUnixTime.c index 479143c..2dd7f75 100644 --- a/unix/tclUnixTime.c +++ b/unix/tclUnixTime.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclUnixTime.c,v 1.1.2.3 1998/11/11 04:54:22 stanton Exp $ + * RCS: @(#) $Id: tclUnixTime.c,v 1.1.2.4 1998/12/10 21:21:58 stanton Exp $ */ #include "tclInt.h" @@ -165,7 +165,7 @@ TclpGetTimeZone (currentTime) #if defined(HAVE_TIMEZONE_VAR) && !defined (TCL_GOT_TIMEZONE) # define TCL_GOT_TIMEZONE static int setTZ = 0; -#ifdef TCL_THREAD +#ifdef TCL_THREADS static Tcl_Mutex tzMutex; #endif int timeZone; -- cgit v0.12