I am almost certainly not the right person to do this work, since I'm
insanely busy trying to get the beta of my game open, and I only learned
of the existence of libssh2 like 3 days ago (thank you guys for making
it!), and I've only actually called it via Net::SSH2, but from my
surface level understanding, it sure seems like Henrik Nordström's post
in this thread is the only sane way forward:
http://comments.gmane.org/gmane.network.ssh.libssh2.devel/5080
Basically, making libssh2 queue up writes (to a point) and then get
pumped by the app if in nonblocking mode, so that the library can send
any kind of housekeeping packets it wants under the hood without hosing
the app or exposing all of that state back out to the API. This would
give the library API some atomicity, it either accepts the write (and
queues it internally), or it rejects the write wholesale with EAGAIN, in
which case the app is welcome to resubmit it, throw it away, change the
buffer pointer, or whatever it wants.
Does anybody disagree that's the right way forward?
Chris
On 2013-02-19 14:59, Daniel Stenberg wrote:
> On Tue, 19 Feb 2013, Chris Hecker wrote:
>
>> It just seems like requiring the exact pointer on subsequent calls is
>> going to be brittle no matter what, and it's going to keep breaking in
>> a lot of different ways.
>
> I agree.
>
>> I guess, practically speaking, is there a patch to fix the known cases
>> of this bug, or a timeline for fixing it/them?
>
> I personally am not working on this (and will not be able to within the
> near future either) and I don't know of anyone else who has spoken up
> about it (or in fact any of the other bugs we have reported). Feel free
> to dive in and give it a go!
>
_______________________________________________
libssh2-devel http://cool.haxx.se/cgi-bin/mailman/listinfo/libssh2-devel
Received on 2013-02-20