mirror of
https://github.com/opnsense/src.git
synced 2026-06-09 08:43:19 -04:00
Don't remove queued SIGCHLD if options contain WNOWAIT, so other
threads still can be notified by the signal.
This commit is contained in:
parent
d69c9c7867
commit
3eb8b8bbeb
1 changed files with 6 additions and 6 deletions
|
|
@ -737,12 +737,6 @@ loop:
|
|||
td->td_retval[0] = p->p_pid;
|
||||
if (status)
|
||||
*status = p->p_xstat; /* convert to int */
|
||||
PROC_LOCK(q);
|
||||
sigqueue_take(p->p_ksi);
|
||||
PROC_UNLOCK(q);
|
||||
|
||||
PROC_UNLOCK(p);
|
||||
|
||||
if (options & WNOWAIT) {
|
||||
|
||||
/*
|
||||
|
|
@ -750,10 +744,16 @@ loop:
|
|||
* Caller does not wish to release the proc
|
||||
* struct just yet.
|
||||
*/
|
||||
PROC_UNLOCK(p);
|
||||
sx_xunlock(&proctree_lock);
|
||||
return (0);
|
||||
}
|
||||
|
||||
PROC_LOCK(q);
|
||||
sigqueue_take(p->p_ksi);
|
||||
PROC_UNLOCK(q);
|
||||
PROC_UNLOCK(p);
|
||||
|
||||
/*
|
||||
* If we got the child via a ptrace 'attach',
|
||||
* we need to give it back to the old parent.
|
||||
|
|
|
|||
Loading…
Reference in a new issue