[gnet-dev] select() on multiple fd



My application needs to listen on several udp & tcp ports.

Every use of select() I see in gnet source is all on one file
discriptor only.  I think it would be useful to have some abstraction
around select call for receiving off multiple file descriptors,
both udp & tcp.

The alternative is to have separate thread for every socket.

I think select() is more efficient.

I remember win32 has some WaitOnmulipleObject() thats supposed to
be a bit like select().




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]