From 41ff9d8c7d4f1224b594eee921b6a966a0585d72 Mon Sep 17 00:00:00 2001 From: Christopher Faylor Date: Wed, 7 Sep 2005 03:10:17 +0000 Subject: * dcrt0.cc (initial_env): Don't attempt stracing if dynamically loaded. (dll_crt0_0): Move console initialization earlier. * init.cc (dll_entry): Move console initialization here. * exceptions.cc (init_console_handler): Fully remove any old console handler. * spawn.cc (spawn_guts): Don't fill out windows argv if we've deduced that this is a cygwin-using program. (av::fixup): Always check executables to see if they are using cygwin1.dll. Don't consider .com files to be scripts. * hookapi.cc (rvadelta): New function. (PEHeaderFromHModule): Simplify slightly. (hook_or_detect_cygwin): Use passed in name argument for "HMODULE" rather than incorrectly reading current program. Calculate delta needed to read image data and file names if this isn't a real "HMODULE". --- winsup/cygwin/init.cc | 1 + 1 file changed, 1 insertion(+) (limited to 'winsup/cygwin/init.cc') diff --git a/winsup/cygwin/init.cc b/winsup/cygwin/init.cc index 491a9d2e3..cad51cc8e 100644 --- a/winsup/cygwin/init.cc +++ b/winsup/cygwin/init.cc @@ -147,6 +147,7 @@ dll_entry (HANDLE h, DWORD reason, void *static_load) case DLL_PROCESS_ATTACH: cygwin_hmodule = (HMODULE) h; dynamically_loaded = (static_load == NULL); + init_console_handler (TRUE); /* Is the stack at an unusual address? This is, an address which is in the usual space occupied by the process image, but below -- cgit v1.2.3