in reply to Re: select appears to ignore pending data on socket.
in thread select appears to ignore pending data on socket.
my problem is, i am going to need to wait on multiple sockets, and receive variable length input. as far as i am aware, recv and sysread only accept a set length of input to pull off the buffer, is this not correct?
the socket may (or may not) have several lines waiting to be read too, just for that extra added complication.
whilst i could write a parser to parse a single recv read into multiple lines, i cant block on the socket, and as far as i am aware, using recv to read more data than is available on the buffer will cause it to block.
is there something else that can be used instead of select? i started out using the event module, but slowly drifted over to select as it seemed much simpler.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: select appears to ignore pending data on socket.
by Somni (Friar) on Nov 04, 2007 at 03:33 UTC |