This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Re: pthread detach problem with glibc 2.2 on SMP
- To: libc-alpha at sourceware dot cygnus dot com
- Subject: Re: pthread detach problem with glibc 2.2 on SMP
- From: Wolfram Gloger <Wolfram dot Gloger at dent dot med dot uni-muenchen dot de>
- Date: Wed, 6 Dec 2000 10:22:02 +0100 ("MET)
- References: <Pine.LNX.4.10.10012060100550.28849-100000@ashi.FootPrints.net>
> Note that this test you have introduced is precisely equivalent to
>
> if (nonexisting_handle(handle, thread_id))
>
> so it should be expressed this way.
You're correct, thanks. Updated patch below.
Regards,
Wolfram.
2000-12-06 Wolfram Gloger <wg@malloc.de>
* join.c (pthread_detach): Allow case where the thread has already
terminated.
--- join.c 2000/12/06 08:37:38 1.1
+++ join.c 2000/12/06 09:20:17
@@ -181,7 +181,7 @@
pthread_descr th;
__pthread_lock(&handle->h_lock, NULL);
- if (invalid_handle(handle, thread_id)) {
+ if (nonexisting_handle(handle, thread_id)) {
__pthread_unlock(&handle->h_lock);
return ESRCH;
}