mirror of
https://git.libssh.org/projects/libssh.git
synced 2026-02-04 12:20:42 +09:00
channels: Fix channel_request_pty_size1 always returning an error.
Fixes bug #88.
This commit is contained in:
committed by
Andreas Schneider
parent
3739bd99c5
commit
a18106d3af
@@ -112,10 +112,15 @@ int channel_request_pty_size1(ssh_channel channel, const char *terminal, int col
|
||||
}
|
||||
|
||||
ssh_log(session, SSH_LOG_FUNCTIONS, "Opening a ssh1 pty");
|
||||
|
||||
channel->request_state = SSH_CHANNEL_REQ_STATE_PENDING;
|
||||
if (packet_send(session) == SSH_ERROR) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
while (channel->request_state == SSH_CHANNEL_REQ_STATE_PENDING) {
|
||||
ssh_handle_packets(session, SSH_TIMEOUT_INFINITE);
|
||||
}
|
||||
|
||||
switch(channel->request_state){
|
||||
case SSH_CHANNEL_REQ_STATE_ERROR:
|
||||
case SSH_CHANNEL_REQ_STATE_PENDING:
|
||||
|
||||
Reference in New Issue
Block a user