summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/cygheap.cc
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2005-06-02 02:36:50 +0000
committerChristopher Faylor <me@cgf.cx>2005-06-02 02:36:50 +0000
commitf9fb1149d5b1c0c15f9a554677019dbc5426ed83 (patch)
tree8fe8ccb9c158b20d4bd15d17bd741b00921c2a32 /winsup/cygwin/cygheap.cc
parent5ac6edefaf90729f8da0b872f89b146242d0946e (diff)
downloadcygnal-f9fb1149d5b1c0c15f9a554677019dbc5426ed83.tar.gz
cygnal-f9fb1149d5b1c0c15f9a554677019dbc5426ed83.tar.bz2
cygnal-f9fb1149d5b1c0c15f9a554677019dbc5426ed83.zip
Revert 2005-05-30 close_all_files changes.
* spawn.cc (spawn_guts): When execing, close all files after the child has synced with us.
Diffstat (limited to 'winsup/cygwin/cygheap.cc')
-rw-r--r--winsup/cygwin/cygheap.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/winsup/cygwin/cygheap.cc b/winsup/cygwin/cygheap.cc
index 3d0ce4b1b..48262ca06 100644
--- a/winsup/cygwin/cygheap.cc
+++ b/winsup/cygwin/cygheap.cc
@@ -61,7 +61,10 @@ cygheap_fixup_in_child (bool execed)
_csbrk ((char *) child_proc_info->cygheap_max - (char *) cygheap);
child_copy (child_proc_info->parent, child_proc_info->dwProcessId, "cygheap", cygheap, cygheap_max);
if (execed)
- CloseHandle (child_proc_info->parent);
+ {
+ CloseHandle (child_proc_info->parent);
+ child_proc_info->parent = NULL;
+ }
cygheap_init ();
debug_fixup_after_fork_exec ();