* spawn.cc (spawn_guts): Fix so that cygthread::terminate is *really* called

only for exec.
* cygthread.cc (cygthread::stub): Don't zero __name here.  That introduces a
race.
This commit is contained in:
Christopher Faylor 2002-10-14 03:32:01 +00:00
parent bfaa0919cb
commit 82fc712075
1 changed files with 4 additions and 2 deletions

View File

@ -715,8 +715,10 @@ spawn_guts (const char * prog_arg, const char *const *argv,
cygheap->fdtab.fixup_before_exec (pi.dwProcessId);
cygheap_setup_for_child_cleanup (newheap, &ciresrv, 1);
if (mode == _P_OVERLAY)
ResumeThread (pi.hThread);
cygthread::terminate ();
{
ResumeThread (pi.hThread);
cygthread::terminate ();
}
}
if (mode != _P_OVERLAY)