mirror of git://sourceware.org/git/glibc.git
(pthread_detach): Allow case where the thread has already terminated.
This commit is contained in:
parent
1ca315fca0
commit
9d241e0c16
|
@ -181,7 +181,7 @@ int pthread_detach(pthread_t thread_id)
|
|||
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;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue