diff options
author | Christopher Faylor <me@cgf.cx> | 2000-09-07 01:18:37 +0000 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2000-09-07 01:18:37 +0000 |
commit | c1644acb233ed749b28b4139604ab134cf1cd34c (patch) | |
tree | 3fd9f31c5c3d2f81996fd6ce65b627959e8fe015 /winsup/cygwin/fhandler_tty.cc | |
parent | 8dec7b03798a822337c86dbbea2f764d165cd61d (diff) | |
download | cygnal-c1644acb233ed749b28b4139604ab134cf1cd34c.tar.gz cygnal-c1644acb233ed749b28b4139604ab134cf1cd34c.tar.bz2 cygnal-c1644acb233ed749b28b4139604ab134cf1cd34c.zip |
* exceptions.cc (signal_exit): Reset all mutos owned by the main thread.
* fhandler.h: Define *_output_mutex macros for serializing tty output.
(fhandler_termios): Remove restart_output_event. Define dummy output mutex
methods.
(fhandler_pty_master): Remove unneeded fixup_after_fork method.
* fhandler_termios.cc (fhandler_termios::line_edit): Acquire output_mutex when
CTRL-S is hit. Release it on CTRL-Q.
* fhandler_tty.cc (fhandler_pty_master::process_slave_output): Remove
inappropriate OutputStopped test here. Just use the output mutex.
(fhandler_pty_master::fhandler_pty_master): Remove obsolete reference to
restart_output_event.
(fhandler_tty_common::close): Ditto.
(fhandler_pty_master::set_close_on_exec): Ditto.
(fhandler_pty_master::fixup_after_fork): Delete.
* tty.cc (tty::common_init): Ditto.
* sync.cc (muto::reset): New method.
* sync.h: Declare above method.
Diffstat (limited to 'winsup/cygwin/fhandler_tty.cc')
-rw-r--r-- | winsup/cygwin/fhandler_tty.cc | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/winsup/cygwin/fhandler_tty.cc b/winsup/cygwin/fhandler_tty.cc index c342be954..6c7e3605e 100644 --- a/winsup/cygwin/fhandler_tty.cc +++ b/winsup/cygwin/fhandler_tty.cc @@ -149,12 +149,6 @@ fhandler_tty_common::__release_output_mutex (const char *fn, int ln) } } -#define acquire_output_mutex(ms) \ - __acquire_output_mutex (__PRETTY_FUNCTION__, __LINE__, ms); - -#define release_output_mutex() \ - __release_output_mutex (__PRETTY_FUNCTION__, __LINE__); - /* Process tty input. */ void @@ -300,13 +294,6 @@ fhandler_pty_master::process_slave_output (char *buf, size_t len, int pktmode_on continue; } - if (get_ttyp ()->OutputStopped) - { - termios_printf ("waiting for restart_output_event"); - WaitForSingleObject (restart_output_event, INFINITE); - termios_printf ("done waiting for restart_output_event"); - } - char *optr; optr = buf; if (pktmode_on) @@ -866,7 +853,6 @@ fhandler_pty_master::fhandler_pty_master (const char *name, DWORD devtype, int u set_cb (sizeof *this); ioctl_request_event = NULL; ioctl_done_event = NULL; - restart_output_event = NULL; pktmode = need_nl = 0; inuse = NULL; } @@ -895,8 +881,6 @@ fhandler_tty_common::close () termios_printf ("CloseHandle (ioctl_done_event), %E"); if (ioctl_request_event && !CloseHandle (ioctl_request_event)) termios_printf ("CloseHandle (ioctl_request_event), %E"); - if (restart_output_event && !CloseHandle (restart_output_event)) - termios_printf ("CloseHandle (restart_output_event), %E"); if (inuse && !CloseHandle (inuse)) termios_printf ("CloseHandle (inuse), %E"); if (!ForceCloseHandle (output_mutex)) @@ -1051,7 +1035,6 @@ void fhandler_pty_master::set_close_on_exec (int val) { this->fhandler_tty_common::set_close_on_exec (val); - set_inheritance (restart_output_event, val); /* FIXME: There is a console handle leak here. */ if (get_ttyp ()->master_pid == GetCurrentProcessId ()) @@ -1062,14 +1045,6 @@ fhandler_pty_master::set_close_on_exec (int val) } void -fhandler_pty_master::fixup_after_fork (HANDLE child) -{ - this->fhandler_tty_common::fixup_after_fork (child); - if (restart_output_event) - fork_fixup (child, restart_output_event, "restart_output_event"); -} - -void fhandler_tty_master::fixup_after_fork (HANDLE child) { this->fhandler_pty_master::fixup_after_fork (child); |