diff options
author | Mike Hommey <mh@glandium.org> | 2014-05-28 05:06:30 (GMT) |
---|---|---|
committer | Jason Evans <je@fb.com> | 2014-05-28 16:43:30 (GMT) |
commit | 17767b5f2b195076a8b57f8489addabb1ee68009 (patch) | |
tree | ae25ac53ea85cb9a30395f318265376556ce9853 | |
parent | 26246af977250a520194a1ced89cbc73ce218ca7 (diff) | |
download | jemalloc-17767b5f2b195076a8b57f8489addabb1ee68009.zip jemalloc-17767b5f2b195076a8b57f8489addabb1ee68009.tar.gz jemalloc-17767b5f2b195076a8b57f8489addabb1ee68009.tar.bz2 |
Correctly return exit code from thd_join on Windows
-rw-r--r-- | test/src/thd.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/test/src/thd.c b/test/src/thd.c index 233242a..7e53625 100644 --- a/test/src/thd.c +++ b/test/src/thd.c @@ -14,7 +14,8 @@ void thd_join(thd_t thd, void **ret) { - WaitForSingleObject(thd, INFINITE); + if (WaitForSingleObject(thd, INFINITE) == WAIT_OBJECT_0 && ret) + GetExitCodeThread(thd, (LPDWORD) ret); } #else |