diff options
| author | hobbs <hobbs> | 2007-05-29 23:35:46 (GMT) |
|---|---|---|
| committer | hobbs <hobbs> | 2007-05-29 23:35:46 (GMT) |
| commit | a043bb4adf6f4d99ad38141670f063342e8a00f1 (patch) | |
| tree | 30e691cb9f8de9e93498d216a1c06f976285d5dc /unix/tclUnixThrd.c | |
| parent | 25feba3793fbdd3d18879ba3e1404aac9d9a34de (diff) | |
| download | tcl-a043bb4adf6f4d99ad38141670f063342e8a00f1.zip tcl-a043bb4adf6f4d99ad38141670f063342e8a00f1.tar.gz tcl-a043bb4adf6f4d99ad38141670f063342e8a00f1.tar.bz2 | |
* unix/tclUnixThrd.c (Tcl_JoinThread): fix for 64-bit handling of
pthread_join exit return code storage. [Bug 1712723]
Diffstat (limited to 'unix/tclUnixThrd.c')
| -rw-r--r-- | unix/tclUnixThrd.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/unix/tclUnixThrd.c b/unix/tclUnixThrd.c index b95e8f7..b74419b 100644 --- a/unix/tclUnixThrd.c +++ b/unix/tclUnixThrd.c @@ -165,8 +165,12 @@ Tcl_JoinThread(threadId, state) { #ifdef TCL_THREADS int result; + unsigned long retcode; - result = pthread_join ((pthread_t) threadId, (VOID**) state); + result = pthread_join((pthread_t) threadId, (void**) &retcode); + if (state) { + *state = (int) retcode; + } return (result == 0) ? TCL_OK : TCL_ERROR; #else return TCL_ERROR; |
