From 9287bcd5348460c4dc49514eb08bc819b6d97771 Mon Sep 17 00:00:00 2001 From: Christopher Faylor Date: Thu, 12 Jan 2006 05:17:12 +0000 Subject: * fhandler_console.cc (set_console_state_for_spawn): Fix to recognize ttys >= 0. --- winsup/cygwin/ChangeLog | 5 +++++ winsup/cygwin/fhandler_console.cc | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 18486f8..7f17cfe 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,5 +1,10 @@ 2006-01-12 Christopher Faylor + * fhandler_console.cc (set_console_state_for_spawn): Fix to recognize + ttys >= 0. + +2006-01-12 Christopher Faylor + * fhandler.h (set_console_state_for_spawn): Whackamole the argument back to a bool. * spawn.cc (spawn_guts): Ditto, i.e., once again call diff --git a/winsup/cygwin/fhandler_console.cc b/winsup/cygwin/fhandler_console.cc index 5ca26d2..e3af924 100644 --- a/winsup/cygwin/fhandler_console.cc +++ b/winsup/cygwin/fhandler_console.cc @@ -147,7 +147,7 @@ void __stdcall set_console_state_for_spawn (bool iscyg) { if (fhandler_console::need_invisible () || iscyg - || (myself->ctty > 0 && myself->ctty != TTY_CONSOLE)) + || (myself->ctty >= 0 && myself->ctty != TTY_CONSOLE)) return; HANDLE h = CreateFile ("CONIN$", GENERIC_READ, FILE_SHARE_WRITE, -- cgit v1.1