From 243a041bd0164aa62813ac4ba5a1a02eb2db455b Mon Sep 17 00:00:00 2001 From: Christopher Faylor Date: Sat, 3 Nov 2001 03:32:27 +0000 Subject: * dll_init.h (class dll_list): Reorder functions to avoid compiler "can't inline" warnings. * security.h (class cygsid): Ditto. * sigproc.cc (get_proc_lock): Ditto. * sigproc.h (class sigframe): Ditto. * sync.h (class muto): Ditto. * fhandler.h (fhandler_base::get_guard): Actually MAKE virtual as previously indicated. * pipe.cc (make_pipe): Remove extraneous set_errno. * syscalls.cc (_open): Ditto. * select.cc (peek_pipe): Need to check that there is still something to read from the pipe after acquiring the mutex since another process/thread could have eaten the input before we got to acquiring the lock. (Thanks to Nick Duffek for this inspiration.) --- winsup/cygwin/syscalls.cc | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'winsup/cygwin/syscalls.cc') diff --git a/winsup/cygwin/syscalls.cc b/winsup/cygwin/syscalls.cc index b11e6795b..b433c3dde 100644 --- a/winsup/cygwin/syscalls.cc +++ b/winsup/cygwin/syscalls.cc @@ -499,9 +499,7 @@ _open (const char *unix_path, int flags, ...) fhandler_base *fh; cygheap_fdnew fd; - if (fd < 0) - set_errno (ENMFILE); - else + if (fd >= 0) { path_conv pc; if (!(fh = cygheap->fdtab.build_fhandler_from_name (fd, unix_path, -- cgit v1.2.3