[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Support external recv and send callbacks
[Thread Prev] | [Thread Next]
- Subject: Support external recv and send callbacks
- From: Joseph Southwell <jsouthwell@xxxxxxxxxxxxx>
- Reply-to: libssh@xxxxxxxxxx
- Date: Thu, 25 May 2017 09:44:50 -0400
- To: libssh@xxxxxxxxxx
This patch allows you to replace the calls to send and recv with alternate callbacks. I am using this because I am running an event driven network stack with stackfull coroutines in c++. This makes the whole thing appear blocking to libssh while still sharing threads efficiently. Socket closure is non blocking so I did not add a callback for that but if somebody wanted to extend this to work with something that isn’t really sockets they would need to add a close callback as well since ssh_disconnect calls close on the socket fd.
Attachment:
0001-got-external-io-working-in-libssh-client.patch
Description: Binary data
Re: Support external recv and send callbacks | Joseph Southwell <jsouthwell@xxxxxxxxxxxxx> |