From 8528ecbde8282bb640a49b531408cc783f05966a Mon Sep 17 00:00:00 2001 From: Christopher Faylor Date: Tue, 1 Jan 2008 18:51:23 +0000 Subject: * newsym: First stab at understanding data as well as functions. * pipe.cc (fhandler_pipe::init): Move more intelligence here. (fhandler_pipe::create): Simplify based on above change. * tty.cc (tty_list::allocate): Remove non-NT code. --- winsup/cygwin/tty.cc | 27 ++------------------------- 1 file changed, 2 insertions(+), 25 deletions(-) (limited to 'winsup/cygwin/tty.cc') diff --git a/winsup/cygwin/tty.cc b/winsup/cygwin/tty.cc index 9793c8cc7..f33530940 100644 --- a/winsup/cygwin/tty.cc +++ b/winsup/cygwin/tty.cc @@ -227,31 +227,8 @@ tty_list::allocate (bool with_console) console = NULL; else if (!(console = GetConsoleWindow ())) { - char oldtitle[TITLESIZE]; - - if (!GetConsoleTitle (oldtitle, TITLESIZE)) - { - termios_printf ("Can't read console title"); - goto out; - } - - char buf[40]; - - __small_sprintf (buf, "cygwin.find.console.%d", myself->pid); - SetConsoleTitle (buf); - for (int times = 0; times < 25; times++) - { - Sleep (10); - if ((console = FindWindow (NULL, buf))) - break; - } - SetConsoleTitle (oldtitle); - Sleep (40); - if (console == NULL) - { - termios_printf ("Can't find console window"); - goto out; - } + termios_printf ("Can't find console window"); + goto out; } /* Is a tty allocated for console? */ -- cgit v1.2.3