aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2003-03-03 03:59:39 +0000
committerChristopher Faylor <me@cgf.cx>2003-03-03 03:59:39 +0000
commit79b8f06e27f24f8126da79689c3fb8e6f0594c3f (patch)
tree40311534663d25745a706385f41dde0f2ec37b04
parentc1f61bbb22d881e8f49d7feb93ecb455002a589e (diff)
downloadnewlib-79b8f06e27f24f8126da79689c3fb8e6f0594c3f.zip
newlib-79b8f06e27f24f8126da79689c3fb8e6f0594c3f.tar.gz
newlib-79b8f06e27f24f8126da79689c3fb8e6f0594c3f.tar.bz2
merge from trunk
-rw-r--r--winsup/cygwin/ChangeLog5
-rw-r--r--winsup/cygwin/fhandler_console.cc3
-rw-r--r--winsup/cygwin/syscalls.cc6
3 files changed, 7 insertions, 7 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog
index f81173f..f1afd94 100644
--- a/winsup/cygwin/ChangeLog
+++ b/winsup/cygwin/ChangeLog
@@ -1,5 +1,10 @@
2003-03-02 Christopher Faylor <cgf@redhat.com>
+ * fhandler_console.cc (fhandler_console::close): Don't decrement
+ in use counter if in vfork fixup stage.
+
+2003-03-02 Christopher Faylor <cgf@redhat.com>
+
* lib/getopt.c: Nuke use of unneeded BSDisms.
2003-03-02 Christopher Faylor <cgf@redhat.com>
diff --git a/winsup/cygwin/fhandler_console.cc b/winsup/cygwin/fhandler_console.cc
index 5b220f6..90edae6 100644
--- a/winsup/cygwin/fhandler_console.cc
+++ b/winsup/cygwin/fhandler_console.cc
@@ -647,7 +647,8 @@ fhandler_console::close (void)
CloseHandle (get_output_handle ());
set_io_handle (NULL);
set_output_handle (NULL);
- if (--open_fhs <= 0 && myself->ctty != FH_CONSOLE)
+ if (!cygheap->fdtab.in_vfork_cleanup () && --open_fhs <= 0
+ && myself->ctty != FH_CONSOLE)
FreeConsole ();
debug_printf ("decremented open_fhs, now %d", open_fhs);
return 0;
diff --git a/winsup/cygwin/syscalls.cc b/winsup/cygwin/syscalls.cc
index 1ec38d0..ba2d958 100644
--- a/winsup/cygwin/syscalls.cc
+++ b/winsup/cygwin/syscalls.cc
@@ -1973,12 +1973,6 @@ mknod_worker (const char *path, mode_t type, mode_t mode, _major_t major,
return symlink_worker (buf, path, true, true);
}
-/* mknod was the call to create directories before the introduction
- of mkdir in 4.2BSD and SVR3. Use of mknod required superuser privs
- so the mkdir command had to be setuid root.
- Although mknod hasn't been implemented yet, some GNU tools (e.g. the
- fileutils) assume its existence so we must provide a stub that always
- fails. */
extern "C" int
mknod (const char *path, mode_t mode, dev_t dev)
{