Subject: Re: libssh2_sftp_seek64 doesn't work

Re: libssh2_sftp_seek64 doesn't work

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Fri, 26 Aug 2011 16:43:01 +0200 (CEST)

On Fri, 26 Aug 2011, Alexander Lamaison wrote:

>> In general our API is designed to assume that you will call the same
>> function again after an EAGAIN has been called.
>
> What about aborting an in-progress operation? How would you do this using
> the libssh2 API? Up till now I've only been using libssh2 in blocking mode
> but, in the near future, I was hoping to use it non-blocking to improve
> user-interaction. My aim was to put the user always in control such that if
> something takes too long and they get impatient they cab simply abort the
> current operation. I imagined that I would do this by setting a flag and
> then simply not continue the loop on the next EAGAIN. Would this be a bad
> way to do it?

Well, I would like that to work but I think that there are situations right
now that will not work like that.

We should work on fixing things so that we never send broken packets, even if
EAGAIN is returned and another function is called afterwards.

But then there's a lot of things we can work on! =)

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