diff options
author | Christopher Faylor <me@cgf.cx> | 2012-06-19 00:31:15 +0000 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2012-06-19 00:31:15 +0000 |
commit | af5cd145835d35519af02d0d226f67eb777e4945 (patch) | |
tree | d31ebb964550d4e73c3f0d63d3fa0d1b502e44f4 /winsup/cygwin/exceptions.cc | |
parent | 88fbcb5afd6d7d687387b22509037d99e2aa07ff (diff) | |
download | cygnal-af5cd145835d35519af02d0d226f67eb777e4945.tar.gz cygnal-af5cd145835d35519af02d0d226f67eb777e4945.tar.bz2 cygnal-af5cd145835d35519af02d0d226f67eb777e4945.zip |
* cygwait.cc (cancelable_wait): Mimic old cygwait behavior more closely wrt
handling of call_signal_handler.
* cygwait.h (WAIT_CANCELED): Move here and redefine.
(WAIT_SIGNALED): Ditto.
* thread.h (WAIT_CANCELED): Delete.
(WAIT_SIGNALED): Ditto.
Diffstat (limited to 'winsup/cygwin/exceptions.cc')
-rw-r--r-- | winsup/cygwin/exceptions.cc | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/winsup/cygwin/exceptions.cc b/winsup/cygwin/exceptions.cc index 3c22e35c3..fe233cf49 100644 --- a/winsup/cygwin/exceptions.cc +++ b/winsup/cygwin/exceptions.cc @@ -715,7 +715,7 @@ handle_sigsuspend (sigset_t tempmask) sigproc_printf ("oldmask %p, newmask %p", oldmask, tempmask); pthread_testcancel (); - cancelable_wait (signal_arrived, NULL, cw_cancel | cw_cancel_self); + cancelable_wait (NULL, NULL, cw_cancel | cw_cancel_self | cw_sig_eintr); set_sig_errno (EINTR); // Per POSIX @@ -748,8 +748,7 @@ sig_handle_tty_stop (int sig) sigproc_printf ("process %d stopped by signal %d", myself->pid, sig); HANDLE w4[2]; w4[0] = sigCONT; - w4[1] = signal_arrived; - switch (WaitForMultipleObjects (2, w4, TRUE, INFINITE)) + switch (cancelable_wait (sigCONT, NULL, cw_sig_eintr)) { case WAIT_OBJECT_0: case WAIT_OBJECT_0 + 1: @@ -1248,7 +1247,7 @@ sigpacket::process () { sigproc_printf ("default signal %d ignored", si.si_signo); if (continue_now) - SetEvent (signal_arrived); + SetEvent (use_tls->signal_arrived); goto done; } |