www.libssh2.org | Daily snapshots | Mailing list archive | Docs | Examples | github

Archive Index This month's Index

Subject: Re: [PATCH] example/sftp_RW_nonblock: do not ignore LIBSSH2_ERROR_EAGAIN

Re: [PATCH] example/sftp_RW_nonblock: do not ignore LIBSSH2_ERROR_EAGAIN

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Mon, 24 Oct 2011 22:23:36 +0200 (CEST)

On Mon, 24 Oct 2011, Kamil Dudka wrote:

> sftp_RW_nonblock.c does not handle LIBSSH2_ERROR_EAGAIN, which causes the
> password authentication to fail. I fixed the example by taking the
> appropriate code from sftp_nonblock.c. Note that sftp_nonblock.c does not
> call select() while looping around libssh2_session_handshake(),
> libssh2_userauth_password(), libssh2_userauth_publickey_fromfile() and
> libssh2_session_disconnect() -- is that intentionally?

It was only like that because of plain laziness. Thanks for fixing the
example, I've pushed your fix now!

-- 
  / daniel.haxx.se
_______________________________________________
libssh2-devel http://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel
Received on 2011-10-24

the libssh2 team