This is the mail archive of the cygwin-patches@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] interruptable accept


On Mon, Jul 01, 2002 at 01:59:56PM +0200, Thomas Pfaff wrote:
> To be corect:
> 1. Call WSAEventSelect.
> 2. WSAWaitForMultipleObjects for socket and signal_arrived.
> 3. If signal arrived set EINTR, WSAEnumNetworkEvents otherwise.
> 4. do accept, then switch sockets back to nonblocking
> 
> I will generate a new patch tonight, then you can decide which one to use.
> The select one was easier one to implement because you don't have to
> deal with nonblocking I/O and multiple events.

If that helps, look into net.cc, wsock_event::wait().  It's doing
something similar for send/recv.

Thanks,
Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Developer                                mailto:cygwin@cygwin.com
Red Hat, Inc.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]