* sigproc.cc (proc_subproc): Don't send a false positive if WNOHANG and no

processes are available for waiting.
This commit is contained in:
Christopher Faylor
2000-10-23 20:50:36 +00:00
parent 38a1798645
commit 06571ff689
2 changed files with 6 additions and 1 deletions

View File

@@ -358,7 +358,7 @@ proc_subproc (DWORD what, DWORD val)
w->next->pid = 0;
if (clearing)
w->next->status = -1; /* flag that a signal was received */
else if (!(w->next->options & WNOHANG))
else if (!potential_match || !(w->next->options & WNOHANG))
w->next->ev = NULL;
if (!SetEvent (oldw))
system_printf ("couldn't wake up wait event %p, %E", oldw);