1
0
mirror of https://github.com/libssh2/libssh2.git synced 2025-11-02 10:53:16 +03:00

Handle Client-To-Server channel windowing.

This commit is contained in:
Sara Golemon
2005-01-20 21:33:30 +00:00
parent bfc2f5039e
commit 5f7470700e
2 changed files with 15 additions and 2 deletions

View File

@@ -475,6 +475,19 @@ static int libssh2_packet_add(LIBSSH2_SESSION *session, unsigned char *data, siz
return retval;
}
break;
case SSH_MSG_CHANNEL_WINDOW_ADJUST:
{
LIBSSH2_CHANNEL *channel = libssh2_channel_locate(session, libssh2_ntohu32(data + 1));
unsigned long bytestoadd = libssh2_ntohu32(data + 5);
if (channel && bytestoadd) {
channel->local.window_size += bytestoadd;
}
LIBSSH2_FREE(session, data);
return 0;
}
break;
}
packet = LIBSSH2_ALLOC(session, sizeof(LIBSSH2_PACKET));