]> sourceware.org Git - newlib-cygwin.git/commitdiff
* dcrt0.cc (hMainProc): Initialize to useful value for use when dll is
authorChristopher Faylor <me@cgf.cx>
Wed, 8 Oct 2003 21:40:33 +0000 (21:40 +0000)
committerChristopher Faylor <me@cgf.cx>
Wed, 8 Oct 2003 21:40:33 +0000 (21:40 +0000)
dynamically loaded.
(shared_info::initialize): Don't initialize user stuff if myself doesn't exit.

winsup/cygwin/ChangeLog
winsup/cygwin/dcrt0.cc
winsup/cygwin/shared.cc

index 3be344dd718e7cdcff7254c921a31c95ef2de254..854ddbd1f1c43552eda1a65b227c5528b096a62c 100644 (file)
@@ -1,3 +1,10 @@
+2003-10-08  Christopher Faylor  <cgf@redhat.com>
+
+       * dcrt0.cc (hMainProc): Initialize to useful value for use when dll is
+       dynamically loaded.
+       (shared_info::initialize): Don't initialize user stuff if myself
+       doesn't exit.
+
 2003-10-08  Corinna Vinschen  <corinna@vinschen.de>
 
        * syscalls.cc (unlink): Don't even try DELETE_ON_CLOSE technique on
index a09b7e81bf27677395650b6371f0629e0a8737f7..b862ee150634ec1b139df61096925827e088b9c1 100644 (file)
@@ -39,7 +39,7 @@ details. */
 
 #define PREMAIN_LEN (sizeof (user_data->premain) / sizeof (user_data->premain[0]))
 
-HANDLE NO_COPY hMainProc;
+HANDLE NO_COPY hMainProc = (HANDLE) -1;
 HANDLE NO_COPY hMainThread;
 
 sigthread NO_COPY mainthread;          // ID of the main thread
index 911465aeaed7ebc554209ecee0861a8c563352d2..b3da33b666035445025fd5acbd6030546bcd7fb8 100644 (file)
@@ -220,7 +220,8 @@ shared_info::initialize ()
   if (!cygheap)
     {
       cygheap_init ();
-      cygheap->user.init ();
+      if (myself)
+       cygheap->user.init ();
     }
 
   heap_init ();
This page took 0.078406 seconds and 5 git commands to generate.