diff options
| author | Daniel Eischen <deischen@FreeBSD.org> | 2000-11-09 05:08:26 +0000 |
|---|---|---|
| committer | Daniel Eischen <deischen@FreeBSD.org> | 2000-11-09 05:08:26 +0000 |
| commit | b5a8a15c2f1a411fad0657422539ef5149287917 (patch) | |
| tree | d2d0239d913bbd0012f7ed1666f8c0055714571a /lib/libpthread/thread/thr_detach.c | |
| parent | 6913c296f7bafef2e42f0d3220157874e25cbd32 (diff) | |
Notes
Diffstat (limited to 'lib/libpthread/thread/thr_detach.c')
| -rw-r--r-- | lib/libpthread/thread/thr_detach.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/libpthread/thread/thr_detach.c b/lib/libpthread/thread/thr_detach.c index 3bade9d5b244..6dd762ab23cd 100644 --- a/lib/libpthread/thread/thr_detach.c +++ b/lib/libpthread/thread/thr_detach.c @@ -65,7 +65,12 @@ pthread_detach(pthread_t pthread) pthread->flags &= ~PTHREAD_FLAGS_IN_JOINQ; /* Make the thread runnable: */ - PTHREAD_NEW_STATE(next_thread,PS_RUNNING); + PTHREAD_NEW_STATE(next_thread, PS_RUNNING); + + /* + * Set the return value for the woken thread: + */ + next_thread->error = ESRCH; } /* |
