]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Fix another race between fork(2) and PROC_REAP_KILL subtree
authorKonstantin Belousov <kib@FreeBSD.org>
Thu, 21 Apr 2022 22:39:58 +0000 (01:39 +0300)
committerKonstantin Belousov <kib@FreeBSD.org>
Wed, 27 Apr 2022 23:27:35 +0000 (02:27 +0300)
commit709783373e57069cc014019a14a806b580e1d62f
treed359082e717480e73274a07982aaf4b95908694f
parent39794d80ad900915e5c4940e9917ba5cb59a8634
Fix another race between fork(2) and PROC_REAP_KILL subtree

where we might not yet see a new child when signalling a process.
Ensure that this cannot happen by stopping all reapping subtree,
which ensures that the child is not inside a syscall, in particular
fork(2).

Reported and tested by: pho
Reviewed by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D35014
sys/kern/kern_procctl.c