diff options
Diffstat (limited to 'winsup/cygwin/fork.cc')
-rw-r--r-- | winsup/cygwin/fork.cc | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/winsup/cygwin/fork.cc b/winsup/cygwin/fork.cc index 9e34da6..1dbfebe 100644 --- a/winsup/cygwin/fork.cc +++ b/winsup/cygwin/fork.cc @@ -397,6 +397,7 @@ frok::parent (volatile char * volatile stack_here) /* Remove impersonation */ cygheap->user.deimpersonate (); fix_impersonation = true; + ch.refresh_cygheap (); while (1) { @@ -601,7 +602,6 @@ extern "C" int fork () { frok grouped; - /* No cygheap allocation beyond this point. */ debug_printf ("entering"); grouped.load_dlls = 0; @@ -635,6 +635,11 @@ fork () return -1; } + /* Put the dll list in topological dependency ordering, in + hopes that the child will have a better shot at loading dlls + properly if it only has to deal with one at a time. */ + dlls.topsort (); + ischild = !!setjmp (grouped.ch.jmp); volatile char * volatile esp; |