[PATCH v2 08/19] nptl: pthread_kill, pthread_cancel should fail after exit (bug 19193)
Adhemerval Zanella
adhemerval.zanella@linaro.org
Thu Aug 26 16:49:56 GMT 2021
On 26/08/2021 07:03, Florian Weimer wrote:
> * Adhemerval Zanella:
>
>> From: Florian Weimer <fweimer@redhat.com>
>>
>> This closes one remaining race condition related to bug 12889: if
>> the thread already exited on the kernel side, returning ESRCH
>> is not correct because that error is reserved for the thread IDs
>> (pthread_t values) whose lifetime has ended. In case of a
>> kernel-side exit and a valid thread ID, no signal needs to be sent
>> and cancellation does not have an effect, so just return 0.
>>
>> sysdeps/pthread/tst-kill4.c triggers undefined behavior and is
>> removed with this commit.
>
> Wrong commit subject: “should [not] fail”
Ack.
More information about the Libc-alpha
mailing list