diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2016-07-26 19:03:07 +0100 |
---|---|---|
committer | Jon Turney <jon.turney@dronecode.org.uk> | 2016-07-27 17:02:08 +0100 |
commit | 32b668d966e5363e7a1e07c3bc70a799c4170675 (patch) | |
tree | 3e29cf3108b95912201653c1016e05d47e1fbfa0 /winsup/cygwin/fhandler.h | |
parent | 10a30e7a258f112c1ada37b12cee924c8575c8d2 (diff) | |
download | cygnal-32b668d966e5363e7a1e07c3bc70a799c4170675.tar.gz cygnal-32b668d966e5363e7a1e07c3bc70a799c4170675.tar.bz2 cygnal-32b668d966e5363e7a1e07c3bc70a799c4170675.zip |
Don't raise SIGTTIN from poll/select
SIGTTIN should be raised when read() is made on a tty in a backgrounded
process, but not when it's tested with poll()/select().
I guess poll()/select() does need to call bg_check(), in order to detect the
error conditions that notices (that is, if bg_check() returns bg_eof or
bg_error, then fd is ready as an error condition exists) so add an optional
parameter to fhandler_base::bg_select() to indicate that signals aren't
desired.
See https://cygwin.com/ml/cygwin-developers/2016-07/msg00004.html
Diffstat (limited to 'winsup/cygwin/fhandler.h')
-rw-r--r-- | winsup/cygwin/fhandler.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/winsup/cygwin/fhandler.h b/winsup/cygwin/fhandler.h index 9f9d9bd8f..3321523ef 100644 --- a/winsup/cygwin/fhandler.h +++ b/winsup/cygwin/fhandler.h @@ -427,7 +427,7 @@ public: { return dev ().native (); } - virtual bg_check_types bg_check (int) {return bg_ok;} + virtual bg_check_types bg_check (int, bool = false) {return bg_ok;} void clear_readahead () { raixput = raixget = ralen = rabuflen = 0; @@ -1233,7 +1233,7 @@ class fhandler_termios: public fhandler_base void sigflush (); int tcgetpgrp (); int tcsetpgrp (int pid); - bg_check_types bg_check (int sig); + bg_check_types bg_check (int sig, bool dontsignal = false); virtual DWORD __acquire_output_mutex (const char *fn, int ln, DWORD ms) {return 1;} virtual void __release_output_mutex (const char *fn, int ln) {} void echo_erase (int force = 0); |