On Mon, 21 Feb 2011, Mateusz Pilski wrote:
I'm using libssh2 library to produce ssh client witch is designed for my
clients needs. So far everything was working well, but i discovered that the
program hangs for few seconds on large data packages.
Using the API in blocking mode, right?
My hunch is that what you're seeing is simply that while receiving a block of
data over a slow network link, then libssh2 will keep returning EAGAIN
internally and the blocking API will sit there waiting for a full packet to
arrive before it returns anyway.
If you really want to avoid that the function blocks for a certain period of
time at some invokes, I think you should consider the non-blocking approach.
Or do you think it can be something else?
--
/ daniel.haxx.se
_______________________________________________
libssh2-devel http://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel