diff options
Diffstat (limited to 'clientloop.c')
-rw-r--r-- | clientloop.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/clientloop.c b/clientloop.c index 0b6fbe88d..c7362caa8 100644 --- a/clientloop.c +++ b/clientloop.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: clientloop.c,v 1.177 2007/01/21 01:41:54 stevesk Exp $ */ | 1 | /* $OpenBSD: clientloop.c,v 1.178 2007/02/20 10:25:14 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> | 3 | * Author: Tatu Ylonen <ylo@cs.hut.fi> |
4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland | 4 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland |
@@ -707,7 +707,7 @@ client_process_control(fd_set *readset) | |||
707 | { | 707 | { |
708 | Buffer m; | 708 | Buffer m; |
709 | Channel *c; | 709 | Channel *c; |
710 | int client_fd, new_fd[3], ver, allowed; | 710 | int client_fd, new_fd[3], ver, allowed, window, packetmax; |
711 | socklen_t addrlen; | 711 | socklen_t addrlen; |
712 | struct sockaddr_storage addr; | 712 | struct sockaddr_storage addr; |
713 | struct confirm_ctx *cctx; | 713 | struct confirm_ctx *cctx; |
@@ -900,9 +900,15 @@ client_process_control(fd_set *readset) | |||
900 | 900 | ||
901 | set_nonblock(client_fd); | 901 | set_nonblock(client_fd); |
902 | 902 | ||
903 | window = CHAN_SES_WINDOW_DEFAULT; | ||
904 | packetmax = CHAN_SES_PACKET_DEFAULT; | ||
905 | if (cctx->want_tty) { | ||
906 | window >>= 1; | ||
907 | packetmax >>= 1; | ||
908 | } | ||
909 | |||
903 | c = channel_new("session", SSH_CHANNEL_OPENING, | 910 | c = channel_new("session", SSH_CHANNEL_OPENING, |
904 | new_fd[0], new_fd[1], new_fd[2], | 911 | new_fd[0], new_fd[1], new_fd[2], window, packetmax, |
905 | CHAN_SES_WINDOW_DEFAULT, CHAN_SES_PACKET_DEFAULT, | ||
906 | CHAN_EXTENDED_WRITE, "client-session", /*nonblock*/0); | 912 | CHAN_EXTENDED_WRITE, "client-session", /*nonblock*/0); |
907 | 913 | ||
908 | /* XXX */ | 914 | /* XXX */ |