[haiku-development] Re: server connection

  • From: "Clemens Zeidler" <clemens.zeidler@xxxxxxxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Tue, 23 Nov 2010 11:10:11 +1300

Am 23.11.2010, 11:00 Uhr, schrieb Rene Gollent <anevilyak@xxxxxxxxx>:

On Mon, Nov 22, 2010 at 4:55 PM, Clemens Zeidler
<clemens.zeidler@xxxxxxxxxxxxxx> wrote:
If there is no such class whats the best way to read all available data? In
case of ssl, SSL_pending returns the number of bytes in the queue. Whats

for a socket, select() or poll() will tell you that the socket is
ready for reading if it has more data available. Note that both of
those will let you check several sockets at once.

is there a way to get the number of waiting bytes from select or poll? don't see it... I could just read one byte at a time as it is done at the moment. But whats about performance? Does recv really ask the server for one byte every time or is there an internal buffer?

thanks, 
        Clemens

Other related posts: