From 20f8e73e3eaf8d7f69786db3f6385095e244e85c Mon Sep 17 00:00:00 2001 From: Aris Adamantiadis Date: Fri, 2 Sep 2011 13:58:37 +0300 Subject: Update libssh to ssh_handle_packets_termination cherry-picked from 0cb5248 Should resolve all timeout problems Conflicts: src/auth.c src/channels.c --- include/libssh/channels.h | 1 + include/libssh/session.h | 5 +++++ 2 files changed, 6 insertions(+) (limited to 'include/libssh') diff --git a/include/libssh/channels.h b/include/libssh/channels.h index 87415e5f..71f89ca5 100644 --- a/include/libssh/channels.h +++ b/include/libssh/channels.h @@ -94,6 +94,7 @@ SSH_PACKET_CALLBACK(channel_rcv_data); ssh_channel ssh_channel_new(ssh_session session); int channel_default_bufferize(ssh_channel channel, void *data, int len, int is_stderr); +int ssh_channel_flush(ssh_channel channel); uint32_t ssh_channel_new_id(ssh_session session); ssh_channel ssh_channel_from_local(ssh_session session, uint32_t id); int channel_write_common(ssh_channel channel, const void *data, diff --git a/include/libssh/session.h b/include/libssh/session.h index d251e7e3..0f5989bc 100644 --- a/include/libssh/session.h +++ b/include/libssh/session.h @@ -62,6 +62,11 @@ enum ssh_pending_call_e { /* libssh calls may block an undefined amount of time */ #define SSH_SESSION_FLAG_BLOCKING 1 +/* codes to use with ssh_handle_packets*() */ +#define SSH_TIMEOUT_INFINITE -1 +#define SSH_TIMEOUT_USER -2 +#define SSH_TIMEOUT_NONBLOCKING 0 + /* members that are common to ssh_session and ssh_bind */ struct ssh_common_struct { struct error_struct error; -- cgit