Proposed fix for cancellation bug found by Neal Ferguson.
Ulrich Drepper
drepper@redhat.com
Tue Sep 26 19:00:00 GMT 2000
Kaz Kylheku <kaz@ashi.footprints.net> writes:
> It happens *always* whenever a thread disables its cancellation and
> then executes waits during which someone calls pthread_cancel on
> it. E.g. create a thread, have it disable cancellation and call
> pthread_join(), then cancel that thread. Spurious wakeup. No
> signals involved.
Well, this is one thing I asked myself when looking at the code. Why
isn't pthread_cancel simply returning if the cancelation state of the
thread is PTHREAD_CANCEL_DISABLE? It seems to make no sense to not to
this test.
--
---------------. ,-. 1325 Chesapeake Terrace
Ulrich Drepper \ ,-------------------' \ Sunnyvale, CA 94089 USA
Red Hat `--' drepper at redhat.com `------------------------
More information about the Libc-alpha
mailing list