diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2005-12-13 09:07:12 +0000 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2005-12-13 09:07:12 +0000 |
commit | 4c848934fea7f6da431ee6c136ce991cc55f1ceb (patch) | |
tree | c1a5de20a7c0a9d0297143484ce66289cd108f58 | |
parent | 82f423291b05df1f2553a87b22b5160e46b46356 (diff) | |
download | cygnal-4c848934fea7f6da431ee6c136ce991cc55f1ceb.tar.gz cygnal-4c848934fea7f6da431ee6c136ce991cc55f1ceb.tar.bz2 cygnal-4c848934fea7f6da431ee6c136ce991cc55f1ceb.zip |
* fhandler_tty.cc (fhandler_tty::open): Close newly created window
station after switching to original window station.
-rw-r--r-- | winsup/cygwin/ChangeLog | 5 | ||||
-rw-r--r-- | winsup/cygwin/fhandler_tty.cc | 7 |
2 files changed, 10 insertions, 2 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 2975f6e59..28abe9d93 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,8 @@ +2005-12-13 Corinna Vinschen <corinna@vinschen.de> + + * fhandler_tty.cc (fhandler_tty::open): Close newly created window + station after switching to original window station. + 2005-12-13 Christopher Faylor <cgf@timesys.com> * fhandler_tty.cc (fhandler_tty::open): Add a comment. diff --git a/winsup/cygwin/fhandler_tty.cc b/winsup/cygwin/fhandler_tty.cc index 47ba20720..0e451b482 100644 --- a/winsup/cygwin/fhandler_tty.cc +++ b/winsup/cygwin/fhandler_tty.cc @@ -605,8 +605,11 @@ fhandler_tty_slave::open (int flags, mode_t) } b = AllocConsole (); // will cause flashing if workstation // stuff fails - if (horig && h != horig) - SetProcessWindowStation (horig); + if (horig && h && h != horig) + { + SetProcessWindowStation (horig); + CloseHandle (h); + } termios_printf ("%d = AllocConsole (), %E", b); if (b) init_console_handler (TRUE); |