summaryrefslogtreecommitdiffstats
path: root/lib/libkse/thread/thr_detach.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libkse/thread/thr_detach.c')
-rw-r--r--lib/libkse/thread/thr_detach.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/libkse/thread/thr_detach.c b/lib/libkse/thread/thr_detach.c
index b0e6fc4..298fdb4 100644
--- a/lib/libkse/thread/thr_detach.c
+++ b/lib/libkse/thread/thr_detach.c
@@ -66,7 +66,9 @@ _pthread_detach(pthread_t pthread)
PTHREAD_NEW_STATE(joiner, PS_RUNNING);
/* Set the return value for the woken thread: */
- joiner->error = ESRCH;
+ joiner->join_status.error = ESRCH;
+ joiner->join_status.ret = NULL;
+ joiner->join_status.thread = NULL;
/*
* Disconnect the joiner from the thread being detached:
OpenPOWER on IntegriCloud