diff options
| author | John Birrell <jb@FreeBSD.org> | 1998-06-25 00:04:21 +0000 |
|---|---|---|
| committer | John Birrell <jb@FreeBSD.org> | 1998-06-25 00:04:21 +0000 |
| commit | ff09ba5fbbb957ac8c4ee21ae02b3900b68b8381 (patch) | |
| tree | 6fcc099ad961308eb1b8470d11258afd0c4a28d6 /lib/libpthread/thread/thr_join.c | |
| parent | e2c597dd6ab5ba92fce3e3bb8bf803fbc88910e9 (diff) | |
Notes
Diffstat (limited to 'lib/libpthread/thread/thr_join.c')
| -rw-r--r-- | lib/libpthread/thread/thr_join.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/libpthread/thread/thr_join.c b/lib/libpthread/thread/thr_join.c index 83b0c2a8c0de..2043b76f5d24 100644 --- a/lib/libpthread/thread/thr_join.c +++ b/lib/libpthread/thread/thr_join.c @@ -77,11 +77,12 @@ pthread_join(pthread_t pthread, void **thread_return) _thread_kern_sched_state(PS_JOIN, __FILE__, __LINE__); /* Check if the thread is not detached: */ - if ((pthread->attr.flags & PTHREAD_DETACHED) == 0) + if ((pthread->attr.flags & PTHREAD_DETACHED) == 0) { /* Check if the return value is required: */ if (thread_return) /* Return the thread's return value: */ *thread_return = pthread->ret; + } else /* Return an error: */ ret = ESRCH; |
