summaryrefslogtreecommitdiffstats
path: root/unix/tclUnixThrd.c
diff options
context:
space:
mode:
authorJoe Mistachkin <joe@mistachkin.com>2015-05-17 23:45:53 (GMT)
committerJoe Mistachkin <joe@mistachkin.com>2015-05-17 23:45:53 (GMT)
commit1668f8980a9b270a5f1fa1d58069b7e26dc12389 (patch)
tree3ce63999aa9439ee1c6f6b2cfe6429a35ac39188 /unix/tclUnixThrd.c
parentbeea2ed90e5ef5ef3f760f1697e207d493813a0d (diff)
downloadtcl-1668f8980a9b270a5f1fa1d58069b7e26dc12389.zip
tcl-1668f8980a9b270a5f1fa1d58069b7e26dc12389.tar.gz
tcl-1668f8980a9b270a5f1fa1d58069b7e26dc12389.tar.bz2
Temporary tweaks to allow Thread package tests to pass on Unix.
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 11df5ee..dc60dc4 100644
--- a/unix/tclUnixThrd.c
+++ b/unix/tclUnixThrd.c
@@ -31,7 +31,7 @@ static Tcl_ThreadDataKey dataKey;
*/
#ifndef TCL_MUTEX_LOCK_SLEEP_TIME
-# define TCL_MUTEX_LOCK_SLEEP_TIME (0)
+# define TCL_MUTEX_LOCK_SLEEP_TIME (50)
#endif
/*
@@ -529,7 +529,11 @@ retry:
* "thread-17.11a". Really, what we want here is just
* to yield to other threads for a while.
*/
+#if 1
+ usleep(TCL_MUTEX_LOCK_SLEEP_TIME);
+#else
Tcl_Sleep(TCL_MUTEX_LOCK_SLEEP_TIME);
+#endif
}
}