mirror of
https://git.libssh.org/projects/libssh.git
synced 2026-02-11 10:40:27 +09:00
Don't grow window if there is no space in the buffer
This commit is contained in:
@@ -516,7 +516,7 @@ SSH_PACKET_CALLBACK(channel_rcv_data){
|
|||||||
if(rest > 0) {
|
if(rest > 0) {
|
||||||
buffer_pass_bytes(buf, rest);
|
buffer_pass_bytes(buf, rest);
|
||||||
}
|
}
|
||||||
if (channel->local_window < WINDOWLIMIT) {
|
if (channel->local_window + buffer_get_rest_len(buf) < WINDOWLIMIT) {
|
||||||
if (grow_window(session, channel, 0) < 0) {
|
if (grow_window(session, channel, 0) < 0) {
|
||||||
leave_function();
|
leave_function();
|
||||||
return -1;
|
return -1;
|
||||||
|
|||||||
Reference in New Issue
Block a user