From 26edeb6a7f6c541a25ee7fa4c201b24fea01cc50 Mon Sep 17 00:00:00 2001 From: Christopher Faylor Date: Tue, 5 Jul 2005 02:05:07 +0000 Subject: * 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. --- winsup/cygwin/spawn.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'winsup/cygwin/spawn.cc') diff --git a/winsup/cygwin/spawn.cc b/winsup/cygwin/spawn.cc index 7f4d8fb0f..6aef5feb6 100644 --- a/winsup/cygwin/spawn.cc +++ b/winsup/cygwin/spawn.cc @@ -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) -- cgit v1.2.3