diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2002-02-09 13:40:48 +0300 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2002-02-09 13:40:48 +0300 |
commit | ff86860ba629f504f059a1ec8b2c9945accaffc6 (patch) | |
tree | 97b365760405c2d544f72b0373badca0d6b53634 /winsup/cygwin/fhandler.h | |
parent | d0672acc75f1101ed426b4a33426391a8073d9d1 (diff) |
* dtable.cc (dtable::dup2): Revert previous patch.
* fhandler.h: Ditto.
(fhandler_socket::recv): Define new method.
(fhandler_socket::send): Ditto.
* fhandler_socket.cc (fhandler_socket::recv): New method.
(fhandler_socket::send): Ditto.
(fhandler_socket::read): Call fhandler_socket::recv() now.
(fhandler_socket::write): Call fhandler_socket::send() now.
* net.cc (class wsock_event): Move definition to wsock_event.h.
(fdsock): Revert previous patch.
(cygwin_recv): Move implementation to fhandler_socket::recv().
(cygwin_send): Move implementation to fhandler_socket::send().
* wsock_event.h: New file.
Diffstat (limited to 'winsup/cygwin/fhandler.h')
-rw-r--r-- | winsup/cygwin/fhandler.h | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/winsup/cygwin/fhandler.h b/winsup/cygwin/fhandler.h index f2b3f1387..1b814272d 100644 --- a/winsup/cygwin/fhandler.h +++ b/winsup/cygwin/fhandler.h @@ -351,9 +351,6 @@ class fhandler_base virtual void seekdir (DIR *, off_t); virtual void rewinddir (DIR *); virtual int closedir (DIR *); - - virtual void set_fd (int nfd) {} - virtual int get_fd () { return -1; } }; class fhandler_socket: public fhandler_base @@ -364,7 +361,6 @@ class fhandler_socket: public fhandler_base HANDLE secret_event; struct _WSAPROTOCOL_INFOA *prot_info_ptr; char *sun_path; - int fd; public: fhandler_socket (); @@ -378,8 +374,12 @@ class fhandler_socket: public fhandler_base void set_shutdown_read () {FHSETF (SHUTRD);} void set_shutdown_write () {FHSETF (SHUTWR);} - int write (const void *ptr, size_t len); + int recv (void *ptr, size_t len, unsigned int flags); int __stdcall read (void *ptr, size_t len) __attribute__ ((regparm (3))); + + int send (const void *ptr, size_t len, unsigned int flags); + int write (const void *ptr, size_t len); + int ioctl (unsigned int cmd, void *); int fcntl (int cmd, void *); off_t lseek (off_t, int) { return 0; } @@ -395,8 +395,6 @@ class fhandler_socket: public fhandler_base select_record *select_read (select_record *s); select_record *select_write (select_record *s); select_record *select_except (select_record *s); - void set_fd (int nfd) { fd = nfd; } - int get_fd () { return fd; } void set_addr_family (int af) {addr_family = af;} int get_addr_family () {return addr_family;} void set_sun_path (const char *path); |