[Bug 283101] pthread_cancel() doesn't cancel a thread that's currently in pause()

[email protected] Thu, 19 Dec 2024 16:39:13 +0000
Newsgroups gmane.os.freebsd.devel.threading
Message-ID <[email protected]/bugzilla/>
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D283101

--- Comment #14 from Konstantin Belousov <[email protected]> ---
So the victim (would be cancelled) thread has cancel_pending =3D 1, which m=
ean
that the main thread successfully executed _thr_cancel() against it.  The
actions of _thr_cancel() are setting cancel_pending, and sending SIGCANCEL
to the target using thr_kill(2).

Since the victim is happily sleeping in sigsuspend(), either SIGCANCEL was =
not
delivered at all, or delivered but ignored due to convoluted threaded handl=
er.
I tried to find any point where SIGCANCEL could be lost, but so far I do not
see it.

Can you please apply the debugging patch below and repeat the same data
gathering?  I want to see if the victim thread' userspace got SIGCANCEL at =
all.

--=20
You are receiving this mail because:
You are the assignee for the bug.=