diff options
Diffstat (limited to 'sys')
-rw-r--r-- | sys/kern/kern_exit.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/kern/kern_exit.c b/sys/kern/kern_exit.c index 67ef152..d7ff969 100644 --- a/sys/kern/kern_exit.c +++ b/sys/kern/kern_exit.c @@ -588,6 +588,11 @@ kern_wait(struct thread *td, pid_t pid, int *status, int options, if (options &~ (WUNTRACED|WNOHANG|WCONTINUED|WLINUXCLONE)) return (EINVAL); loop: + if (q->p_flag & P_STATCHILD) { + PROC_LOCK(q); + q->p_flag &= ~P_STATCHILD; + PROC_UNLOCK(q); + } nfound = 0; sx_xlock(&proctree_lock); LIST_FOREACH(p, &q->p_children, p_sibling) { |