aboutsummaryrefslogtreecommitdiff
path: root/winsup/cygwin/pipe.cc
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2003-01-03 06:20:23 +0000
committerChristopher Faylor <me@cgf.cx>2003-01-03 06:20:23 +0000
commitf3afe99b0b8de188814ae7e7f841d2566532ef27 (patch)
treec0ecbf0fe730c3fe33fdfc27ea4f3028599dd5fb /winsup/cygwin/pipe.cc
parent7b061fd844f6ade0087cfde28eea223b2aa778a2 (diff)
downloadnewlib-f3afe99b0b8de188814ae7e7f841d2566532ef27.zip
newlib-f3afe99b0b8de188814ae7e7f841d2566532ef27.tar.gz
newlib-f3afe99b0b8de188814ae7e7f841d2566532ef27.tar.bz2
* dtable.h (dtable::in_vfork_cleanup): New function. True if vfork cleanup
needed. * dtable.cc (dtable::vfork_parent_restore): Remove assertion. * pipe.cc (fhandler_pipe::close): Don't close read_state during fork_fixup since it wasn't inherited.
Diffstat (limited to 'winsup/cygwin/pipe.cc')
-rw-r--r--winsup/cygwin/pipe.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/winsup/cygwin/pipe.cc b/winsup/cygwin/pipe.cc
index 9b07410..ee3c725 100644
--- a/winsup/cygwin/pipe.cc
+++ b/winsup/cygwin/pipe.cc
@@ -90,7 +90,7 @@ int fhandler_pipe::close ()
CloseHandle (guard);
if (writepipe_exists)
CloseHandle (writepipe_exists);
- if (read_state)
+ if (read_state && !cygheap->fdtab.in_vfork_cleanup ())
CloseHandle (read_state);
return res;
}