* dcrt0.cc (reent_data): Reluctantly resurrect.

(__cygwin_user_data::impure_ptr): Ditto.
(_dll_crt0): Reluctantly initialize _impure_ptr here.
(initialize_main_tls): Eliminate local_clib initialization since it now happens
in init_thread.
* init.cc (dll_entry): Reluctantly remove code which set _impure_ptr to the
main thread's local_clib.
* perthread.h (reent_data): Remove obsolete declaration.
* sigproc.cc (proc_subproc): Add more debugging output.
(get_proc_lock): Ditto.
*dcrt0.cc (dll_crt0_1): Allocate argv[0] via malloc since main thread could
exit.
This commit is contained in:
Christopher Faylor
2003-12-26 04:40:52 +00:00
parent 1f32b7b382
commit 76832a5b32
6 changed files with 46 additions and 20 deletions

View File

@ -52,7 +52,7 @@ dll_entry (HANDLE h, DWORD reason, void *static_load)
{
case DLL_PROCESS_ATTACH:
dynamically_loaded = (static_load == NULL);
__cygwin_user_data.impure_ptr = &_my_tls.local_clib;
// __cygwin_user_data.impure_ptr = &_my_tls.local_clib;
_my_tls.stackptr = _my_tls.stack;
break;
case DLL_PROCESS_DETACH:
@ -60,6 +60,8 @@ dll_entry (HANDLE h, DWORD reason, void *static_load)
case DLL_THREAD_ATTACH:
munge_threadfunc (h);
break;
case DLL_THREAD_DETACH:
break;
}
return 1;
}