diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2001-11-08 18:01:44 +0300 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2001-11-08 18:01:44 +0300 |
commit | 036fd823dcf4cf161304a894258477d175b1c3f0 (patch) | |
tree | 45468342744cced78308473cd537e83063d726e7 /winsup/cygwin/syscalls.cc | |
parent | 418c02db8faef0540377e40c24fee433f2f9cb12 (diff) |
* select.cc (fhandler_tty_slave::ready_for_read): Return 0 on EBADF.
* syscalls.cc (_read): If ready_for_read() failed, save errno from
being overwritten by signal handler call.
Diffstat (limited to 'winsup/cygwin/syscalls.cc')
-rw-r--r-- | winsup/cygwin/syscalls.cc | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/winsup/cygwin/syscalls.cc b/winsup/cygwin/syscalls.cc index 3b2104d7f..fc069ca73 100644 --- a/winsup/cygwin/syscalls.cc +++ b/winsup/cygwin/syscalls.cc @@ -314,6 +314,7 @@ _read (int fd, void *ptr, size_t len) debug_printf ("non-interruptible read\n"); else if (!cfd->ready_for_read (fd, wait)) { + set_sig_errno (get_errno ()); res = -1; goto out; } |