I've noticed that the new sftp_readnb and sftp_writenb functions don't  
ever seem to block.  I profiled the libssh2_sftp_nonblock sample and I  
am seeing half of the time still spent blocking, even when doing the  
largest reads possible.

Looking through the code, I think the reason is because  
_libssh2_sftp_read, the internal function for reading, calls  
libssh2_sftp_packet_requirev to acquire the data packet, which in turn  
calls libssh2_sftp_packet_read in blocking mode.  This means that the  
entire data packet will be read in blocking mode, which is the  
behavior I am observing.

Is this the correct assessment, or am I crazy?

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
libssh2-devel mailing list
libssh2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libssh2-devel

Reply via email to