* cygtls.h (_cygtls): Perform minor reformatting.
* winsup.h (close_all_files): Reflect argument change. * dtable.cc (close_all_files): Ditto. * dtable.h: Ditto. * fhandler.h: Ditto. * spawn.cc (spawn_guts): Move close_all_files back to its original location in first P_OVERLAY test but use argument denoting that handles are only supposed to be closed, not released (more work to be done here). * syscalls.cc (close_all_files): Take an argument denoting whether to release closed files or not. * path.cc (symlink): Change argument names to reflect linux man page. (symlink_worker): Ditto. Also appropriately set ENOENT for empty strings.
This commit is contained in:
@ -800,6 +800,7 @@ spawn_guts (const char * prog_arg, const char *const *argv,
|
||||
strace.execing = 1;
|
||||
myself.hProcess = hExeced = pi.hProcess;
|
||||
strcpy (myself->progname, real_path); // FIXME: race?
|
||||
close_all_files (true);
|
||||
sigproc_printf ("new process name %s", myself->progname);
|
||||
/* If wr_proc_pipe doesn't exist then this process was not started by a cygwin
|
||||
process. So, we need to wait around until the process we've just "execed"
|
||||
@ -869,7 +870,6 @@ spawn_guts (const char * prog_arg, const char *const *argv,
|
||||
switch (mode)
|
||||
{
|
||||
case _P_OVERLAY:
|
||||
close_all_files ();
|
||||
if (!synced)
|
||||
/* let myself.exit handle this */;
|
||||
else if (myself->wr_proc_pipe)
|
||||
|
Reference in New Issue
Block a user