diff options
author | Christopher Faylor <me@cgf.cx> | 2011-11-21 23:13:30 +0400 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2011-11-21 23:13:30 +0400 |
commit | 15660c23ab4e99605b638f791b71d4d68f4ab436 (patch) | |
tree | 5db68b40c8d8444bc4f8cde9b964850db783f8cd /winsup/cygwin/sigproc.cc | |
parent | 8b0e312bf1379d45f83a68091683df5e87bab454 (diff) |
* sigproc.cc (remove_proc): Don't do busy loop when execing since thread could
have been terminated prior to setting flag.
* signal.cc (sigwaitinfo): Zero event before closing to signal other threads
that it is no longer available.
Diffstat (limited to 'winsup/cygwin/sigproc.cc')
-rw-r--r-- | winsup/cygwin/sigproc.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/winsup/cygwin/sigproc.cc b/winsup/cygwin/sigproc.cc index 663abfb5c..a48bd43fd 100644 --- a/winsup/cygwin/sigproc.cc +++ b/winsup/cygwin/sigproc.cc @@ -1106,8 +1106,9 @@ remove_proc (int ci) moving it or it may become confused. The chances are very high that the proc_waiter thread has already done this by the time we get here. */ - while (!procs[nprocs].waiter_ready) - yield (); + if (!have_execed) + while (!procs[nprocs].waiter_ready) + yield (); procs[ci] = procs[nprocs]; } return 0; |