summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2020-10-08 12:11:11 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2020-10-08 12:11:11 (GMT)
commit4a3369807be6e501ec6452edf99a73514c24d861 (patch)
treee7a85fb10396fe26d7d4531bd3c7f837563c6b40
parent5039e7ce17a9ea6c7352b39a0bd70e31433b7843 (diff)
downloadtcl-4a3369807be6e501ec6452edf99a73514c24d861.zip
tcl-4a3369807be6e501ec6452edf99a73514c24d861.tar.gz
tcl-4a3369807be6e501ec6452edf99a73514c24d861.tar.bz2
Eliminate warnings when compiling with -Wundef
-rw-r--r--generic/tclAlloc.c2
-rw-r--r--generic/tclCkalloc.c2
-rw-r--r--generic/tclEvent.c2
-rw-r--r--generic/tclObj.c2
-rw-r--r--win/tclWinPort.h6
5 files changed, 7 insertions, 7 deletions
diff --git a/generic/tclAlloc.c b/generic/tclAlloc.c
index dd83385..cc683b6 100644
--- a/generic/tclAlloc.c
+++ b/generic/tclAlloc.c
@@ -24,7 +24,7 @@
#include "tclInt.h"
#if !defined(TCL_THREADS) || !defined(USE_THREAD_ALLOC)
-#if USE_TCLALLOC
+#if defined(USE_TCLALLOC) && USE_TCLALLOC
/*
* We should really make use of AC_CHECK_TYPE(caddr_t) here, but it can wait
diff --git a/generic/tclCkalloc.c b/generic/tclCkalloc.c
index 0dc1dca..6d661f6 100644
--- a/generic/tclCkalloc.c
+++ b/generic/tclCkalloc.c
@@ -1324,7 +1324,7 @@ TclFinalizeMemorySubsystem(void)
Tcl_MutexUnlock(ckallocMutexPtr);
#endif
-#if USE_TCLALLOC
+#if defined(USE_TCLALLOC) && USE_TCLALLOC
TclFinalizeAllocSubsystem();
#endif
}
diff --git a/generic/tclEvent.c b/generic/tclEvent.c
index ae40850..d8f5119 100644
--- a/generic/tclEvent.c
+++ b/generic/tclEvent.c
@@ -1045,7 +1045,7 @@ TclInitSubsystems(void)
TclInitThreadStorage(); /* Creates hash table for
* thread local storage */
-#if USE_TCLALLOC
+#if defined(USE_TCLALLOC) && USE_TCLALLOC
TclInitAlloc(); /* Process wide mutex init */
#endif
#ifdef TCL_MEM_DEBUG
diff --git a/generic/tclObj.c b/generic/tclObj.c
index 70b2b1e..2ec5eb8 100644
--- a/generic/tclObj.c
+++ b/generic/tclObj.c
@@ -161,7 +161,7 @@ typedef struct PendingObjData {
static PendingObjData pendingObjData;
#define ObjInitDeletionContext(contextPtr) \
PendingObjData *const contextPtr = &pendingObjData
-#elif HAVE_FAST_TSD
+#elif defined(HAVE_FAST_TSD)
static __thread PendingObjData pendingObjData;
#define ObjInitDeletionContext(contextPtr) \
PendingObjData *const contextPtr = &pendingObjData
diff --git a/win/tclWinPort.h b/win/tclWinPort.h
index 3d61a39..8641e5e 100644
--- a/win/tclWinPort.h
+++ b/win/tclWinPort.h
@@ -297,7 +297,7 @@ typedef DWORD_PTR * PDWORD_PTR;
* defined in header files above.
*/
-#if TCL_UNION_WAIT
+#ifdef TCL_UNION_WAIT
# define WAIT_STATUS_TYPE union wait
#else
# define WAIT_STATUS_TYPE int
@@ -439,10 +439,10 @@ typedef DWORD_PTR * PDWORD_PTR;
* Define pid_t and uid_t if they're not already defined.
*/
-#if ! TCL_PID_T
+#if !defined(TCL_PID_T)
# define pid_t int
#endif /* !TCL_PID_T */
-#if ! TCL_UID_T
+#if !defined(TCL_UID_T)
# define uid_t int
#endif /* !TCL_UID_T */