summaryrefslogtreecommitdiffstats
path: root/unix/tclUnixThrd.c
diff options
context:
space:
mode:
Diffstat (limited to 'unix/tclUnixThrd.c')
-rw-r--r--unix/tclUnixThrd.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/unix/tclUnixThrd.c b/unix/tclUnixThrd.c
index ca3e592..fb6e8cb 100644
--- a/unix/tclUnixThrd.c
+++ b/unix/tclUnixThrd.c
@@ -54,7 +54,6 @@ static pthread_mutex_t *allocLockPtr = &allocLock;
-#ifdef TCL_THREADS
/*
*----------------------------------------------------------------------
@@ -82,6 +81,7 @@ Tcl_CreateThread(idPtr, proc, clientData, stackSize, flags)
int flags; /* Flags controlling behaviour of
* the new thread */
{
+#ifdef TCL_THREADS
pthread_attr_t attr;
int result;
@@ -128,8 +128,12 @@ Tcl_CreateThread(idPtr, proc, clientData, stackSize, flags)
}
pthread_attr_destroy(&attr);
return result;
+#else
+ return TCL_ERROR;
+#endif /* TCL_THREADS */
}
+#ifdef TCL_THREADS
/*
*----------------------------------------------------------------------
*