From d5cb221b85cc8120c0947d74178f762c84d47a96 Mon Sep 17 00:00:00 2001 From: Christopher Faylor Date: Sun, 5 Jun 2011 02:10:31 +0000 Subject: * fhandler_console.cc (fhandler_console::open_shared_console): Don't zero handle to open_shared since it is supposed to be an input. (enum_windows): Set handle input to open_shared to NULL since it does not represent any previously opened shared region. * shared.cc (open_shared): Tweak debugging output. --- winsup/cygwin/fhandler_console.cc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'winsup/cygwin/fhandler_console.cc') diff --git a/winsup/cygwin/fhandler_console.cc b/winsup/cygwin/fhandler_console.cc index 399830b79..6766cb02e 100644 --- a/winsup/cygwin/fhandler_console.cc +++ b/winsup/cygwin/fhandler_console.cc @@ -82,7 +82,6 @@ fhandler_console::open_shared_console (HWND hw, HANDLE& h, bool& create) { wchar_t namebuf[(sizeof "XXXXXXXXXXXXXXXXXX-consNNNNNNNNNN")]; __small_swprintf (namebuf, L"%S-cons%p", &installation_key, hw); - h = NULL; shared_locations m = create ? SH_JUSTCREATE: SH_JUSTOPEN; console_state *res = (console_state *) @@ -108,7 +107,7 @@ enum_windows (HWND hw, LPARAM lp) console_unit *this1 = (console_unit *) lp; if (hw == this1->me) return TRUE; - HANDLE h; + HANDLE h = NULL; fhandler_console::console_state *cs; if ((cs = fhandler_console::open_shared_console (hw, h))) { -- cgit v1.2.3