diff options
author | Christopher Faylor <me@cgf.cx> | 2012-10-12 01:19:04 +0000 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2012-10-12 01:19:04 +0000 |
commit | fe0cb311370003fc5839e592c79b460aa841a63b (patch) | |
tree | a0c503ba875c81831a4462a3992658bb668a440c /winsup/cygwin/fhandler_termios.cc | |
parent | 52985c1686253dbfe45756bdbefe9568ef401c4e (diff) | |
download | cygnal-fe0cb311370003fc5839e592c79b460aa841a63b.tar.gz cygnal-fe0cb311370003fc5839e592c79b460aa841a63b.tar.bz2 cygnal-fe0cb311370003fc5839e592c79b460aa841a63b.zip |
* fhandler_termios.cc (fhandler_termios::line_edit): Don't manipulate
output_mutex on CTRL-S/CTRL-Q to avoid a deadlock.
* fhandler_tty.cc (fhandler_pty_slave::write): Loop when output_stopped is
detected before acquiring output_mutex. Acquire output_mutex in the loop for
each write.
* tty.h: Remove some obsolete defines.
(tty_min::output_stopped): Make 'bool'.
Diffstat (limited to 'winsup/cygwin/fhandler_termios.cc')
-rw-r--r-- | winsup/cygwin/fhandler_termios.cc | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/winsup/cygwin/fhandler_termios.cc b/winsup/cygwin/fhandler_termios.cc index 18afacf1d..956786fae 100644 --- a/winsup/cygwin/fhandler_termios.cc +++ b/winsup/cygwin/fhandler_termios.cc @@ -286,17 +286,13 @@ fhandler_termios::line_edit (const char *rptr, int nread, termios& ti) if (CCEQ (ti.c_cc[VSTOP], c)) { if (!tc ()->output_stopped) - { - tc ()->output_stopped = 1; - acquire_output_mutex (INFINITE); - } + tc ()->output_stopped = true; continue; } else if (CCEQ (ti.c_cc[VSTART], c)) { restart_output: - tc ()->output_stopped = 0; - release_output_mutex (); + tc ()->output_stopped = false; continue; } else if ((ti.c_iflag & IXANY) && tc ()->output_stopped) |