aboutsummaryrefslogtreecommitdiff
path: root/libssh
diff options
context:
space:
mode:
authorVic Lee <llyzs@163.com>2009-08-16 18:28:05 +0800
committerAndreas Schneider <mail@cynapses.org>2009-08-16 14:40:18 +0200
commit2c4bbe51dd614725e21e479ce4879fc90182bd90 (patch)
treed5539c5cee005a794c7deff4baf24dc9b2238bac /libssh
parent756d441f8c55d97396d7575188a1f48e4827ff58 (diff)
downloadlibssh-2c4bbe51dd614725e21e479ce4879fc90182bd90.tar.gz
libssh-2c4bbe51dd614725e21e479ce4879fc90182bd90.tar.xz
libssh-2c4bbe51dd614725e21e479ce4879fc90182bd90.zip
Fix return code from packet_wait in channel_request
Signed-off-by: Andreas Schneider <mail@cynapses.org>
Diffstat (limited to 'libssh')
-rw-r--r--libssh/channels.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libssh/channels.c b/libssh/channels.c
index c536842b..473d1f79 100644
--- a/libssh/channels.c
+++ b/libssh/channels.c
@@ -1057,7 +1057,7 @@ static int channel_request(ssh_channel channel, const char *request,
}
rc = packet_wait(session, SSH2_MSG_CHANNEL_SUCCESS, 1);
- if (rc) {
+ if (rc == SSH_ERROR) {
if (session->in_packet.type == SSH2_MSG_CHANNEL_FAILURE) {
ssh_log(session, SSH_LOG_PACKET,
"%s channel request failed", request);