1
0
mirror of https://github.com/moparisthebest/curl synced 2024-08-13 17:03:50 -04:00

SCP upload done non-blocking

This commit is contained in:
Daniel Stenberg 2007-02-07 22:00:33 +00:00
parent 7a39b98471
commit 04e6568a7e

View File

@ -615,9 +615,15 @@ ssize_t Curl_scp_send(struct connectdata *conn, int sockindex,
* NOTE: we should not store nor rely on connection-related data to be * NOTE: we should not store nor rely on connection-related data to be
* in the SessionHandle struct * in the SessionHandle struct
*/ */
#ifdef LIBSSH2CHANNEL_EAGAIN
nwrite = (ssize_t)
libssh2_channel_writenb(conn->data->reqdata.proto.ssh->ssh_channel,
mem, len);
#else
nwrite = (ssize_t) nwrite = (ssize_t)
libssh2_channel_write(conn->data->reqdata.proto.ssh->ssh_channel, libssh2_channel_write(conn->data->reqdata.proto.ssh->ssh_channel,
mem, len); mem, len);
#endif
(void)sockindex; (void)sockindex;
return nwrite; return nwrite;
} }