aboutsummaryrefslogtreecommitdiff
path: root/winsup/cygwin/init.cc
diff options
context:
space:
mode:
Diffstat (limited to 'winsup/cygwin/init.cc')
-rw-r--r--winsup/cygwin/init.cc5
1 files changed, 2 insertions, 3 deletions
diff --git a/winsup/cygwin/init.cc b/winsup/cygwin/init.cc
index 94453f6..9b7201c 100644
--- a/winsup/cygwin/init.cc
+++ b/winsup/cygwin/init.cc
@@ -51,14 +51,13 @@ dll_entry (HANDLE h, DWORD reason, void *static_load)
switch (reason)
{
case DLL_PROCESS_ATTACH:
- _my_tls.stackptr = _my_tls.stack;
dynamically_loaded = (static_load == NULL);
+ __cygwin_user_data.impure_ptr = &_my_tls.local_clib;
+ _my_tls.stackptr = _my_tls.stack;
break;
case DLL_PROCESS_DETACH:
break;
case DLL_THREAD_ATTACH:
- if (MT_INTERFACE->reent_key.set (&MT_INTERFACE->reents))
- api_fatal ("thread initialization failed");
munge_threadfunc (h);
break;
}