diff options
author | iedowse <iedowse@FreeBSD.org> | 2002-04-27 22:41:41 +0000 |
---|---|---|
committer | iedowse <iedowse@FreeBSD.org> | 2002-04-27 22:41:41 +0000 |
commit | 08fc3f3e820a5a51df7f3278a29c62bb1dc43501 (patch) | |
tree | ab3f8fe2b905f86c563bfbca269c90f5c83f3a4f /sys/kern/kern_exit.c | |
parent | cc7a68c868d5e86840533d81c70944fd3896aaea (diff) | |
download | FreeBSD-src-08fc3f3e820a5a51df7f3278a29c62bb1dc43501.zip FreeBSD-src-08fc3f3e820a5a51df7f3278a29c62bb1dc43501.tar.gz |
Avoid the user-visible effect of setting SA_NOCLDWAIT when the
SIGCHLD handler is SIG_IGN. This is a reimplementation of the
problematic revision 1.131 of kern_exit.c. To avoid accessing process
UPAGES, we set a new procsig flag when the SIGCHLD handler is SIG_IGN
and use that instead.
Diffstat (limited to 'sys/kern/kern_exit.c')
-rw-r--r-- | sys/kern/kern_exit.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/kern/kern_exit.c b/sys/kern/kern_exit.c index 0d06804..c9bf40b 100644 --- a/sys/kern/kern_exit.c +++ b/sys/kern/kern_exit.c @@ -368,10 +368,10 @@ exit1(td, rv) /* * Notify parent that we're gone. If parent has the PS_NOCLDWAIT - * flag set, notify process 1 instead (and hope it will handle - * this situation). + * flag set, or if the handler is set to SIG_IGN, notify process + * 1 instead (and hope it will handle this situation). */ - if (p->p_pptr->p_procsig->ps_flag & PS_NOCLDWAIT) { + if (p->p_pptr->p_procsig->ps_flag & (PS_NOCLDWAIT | PS_CLDSIGIGN)) { struct proc *pp = p->p_pptr; PROC_UNLOCK(pp); proc_reparent(p, initproc); |