* fhandler.h (fhandler_fifo::arm): Declare new function.

* fhandler_fifo.cc (fhandler_fifo::arm): Define new function.
(fhandler_fifo::open): Fix handling of RDWR pipes to avoid opening a second
handle.  Use arm() function to set events.
(fhandler_fifo::raw_read): Correctly go into "connect again logic" when we
detect another writer is available.  Use arm() function to set event.
* pipe.cc (fhandler_pipe::create): Add more detail to debugging output.
This commit is contained in:
Christopher Faylor
2012-01-22 21:43:25 +00:00
parent 5b09af7a51
commit 1ad58ee709
4 changed files with 49 additions and 20 deletions

View File

@ -738,6 +738,7 @@ public:
bool isfifo () const { return true; }
void set_close_on_exec (bool val);
void __stdcall raw_read (void *ptr, size_t& ulen) __attribute__ ((regparm (3)));
bool arm (HANDLE h);
void fixup_after_fork (HANDLE);
int __stdcall fstatvfs (struct statvfs *buf) __attribute__ ((regparm (2)));
select_record *select_read (select_stuff *);