CVSROOT:        /cvs
Module name:    src
Changes by:     js...@cvs.openbsd.org   2020/11/16 11:37:06

Modified files:
        sys/kern       : kern_exit.c 

Log message:
Prevent exit status from being clobbered on thread exit.

Ensure that EXIT_NORMAL only runs once by guarding it with PS_EXITING.

It was previously possible for EXIT_NORMAL to be run twice, depending on
which thread called exit() and the order in which the threads were torn
down. This is due to the P_HASSIBLING() check triggering the last thread
to run EXIT_NORMAL, even though it may have already been run via an exit()
call.

ok kettenis@ visa@

Reply via email to