Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2001-11-04 05:31:58 +0300
committerChristopher Faylor <me@cgf.cx>2001-11-04 05:31:58 +0300
commit476dfb657b1b66c1c98484f047749e4be1a5b14d (patch)
treed06213be681ef2bf6046b4d3295c44ac059a4a7b /winsup/cygwin/fhandler.h
parentf41d24a14d5672c152938abd44226108d236aca1 (diff)
* fhandler.h (fhandler_base::ready_for_read): Remove unused argument.
(fhandler_tty_slave::ready_for_read): Ditto. (select_record): Remove poll, initialize peek. * select.cc: Remove all poll functions, throughout. Change second argument of peek_* functions to 'bool' throughout. Specifically initialize *_ready variables throughout. (select_stuff::poll): Subsume previous poll functionality. (peek_pipe): Don't grab guard mutex when in select loop. select()/read() is racy by design so there is no need to worry about a race in select(). (fhandler_base::ready_for_read): Remove unused argument. (fhandler_tty_slave::ready_for_read): Ditto. * syscalls.cc (_read): Eliminate third argument in ready_for_read call.
Diffstat (limited to 'winsup/cygwin/fhandler.h')
-rw-r--r--winsup/cygwin/fhandler.h10
1 files changed, 4 insertions, 6 deletions
diff --git a/winsup/cygwin/fhandler.h b/winsup/cygwin/fhandler.h
index a98bec48f..31ec5fe64 100644
--- a/winsup/cygwin/fhandler.h
+++ b/winsup/cygwin/fhandler.h
@@ -324,7 +324,7 @@ class fhandler_base
virtual select_record *select_read (select_record *s);
virtual select_record *select_write (select_record *s);
virtual select_record *select_except (select_record *s);
- virtual int ready_for_read (int fd, DWORD howlong, int ignra);
+ virtual int ready_for_read (int fd, DWORD howlong);
virtual const char * get_native_name ()
{
return windows_device_names[FHDEVN (status)];
@@ -793,7 +793,7 @@ class fhandler_tty_slave: public fhandler_tty_common
off_t lseek (off_t, int) { return 0; }
select_record *select_read (select_record *s);
- int ready_for_read (int fd, DWORD howlong, int ignra);
+ int ready_for_read (int fd, DWORD howlong);
};
class fhandler_pty_master: public fhandler_tty_common
@@ -1017,9 +1017,7 @@ struct select_record
bool read_ready, write_ready, except_ready;
bool read_selected, write_selected, except_selected;
int (*startup) (select_record *me, class select_stuff *stuff);
- int (*poll) (select_record *me, fd_set *readfds, fd_set *writefds,
- fd_set *exceptfds);
- int (*peek) (select_record *, int);
+ int (*peek) (select_record *, bool);
int (*verify) (select_record *me, fd_set *readfds, fd_set *writefds,
fd_set *exceptfds);
void (*cleanup) (select_record *me, class select_stuff *stuff);
@@ -1029,7 +1027,7 @@ struct select_record
fh (in_fh), saw_error (0), windows_handle (0),
read_ready (0), write_ready (0), except_ready (0),
read_selected (0), write_selected (0), except_selected (0),
- startup (NULL), poll (NULL), verify (NULL), cleanup (NULL),
+ startup (NULL), peek (NULL), verify (NULL), cleanup (NULL),
next (NULL) {}
};