diff options
author | Dag-Erling Smørgrav <des@FreeBSD.org> | 2008-07-23 09:15:38 +0000 |
---|---|---|
committer | Dag-Erling Smørgrav <des@FreeBSD.org> | 2008-07-23 09:15:38 +0000 |
commit | 24cf82b14a50efe0bb150e7651f451a3cc36103b (patch) | |
tree | 31274ced9514914f9504202c6e49c93d509e710d /clientloop.c | |
parent | 024ab8dd1d8c50215dd4a503416b095663d4346c (diff) |
Notes
Diffstat (limited to 'clientloop.c')
-rw-r--r-- | clientloop.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/clientloop.c b/clientloop.c index 4c5108199c96..c7362caa8ccc 100644 --- a/clientloop.c +++ b/clientloop.c @@ -1,4 +1,4 @@ -/* $OpenBSD: clientloop.c,v 1.176 2006/10/11 12:38:03 markus Exp $ */ +/* $OpenBSD: clientloop.c,v 1.178 2007/02/20 10:25:14 djm Exp $ */ /* * Author: Tatu Ylonen <ylo@cs.hut.fi> * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland @@ -707,7 +707,7 @@ client_process_control(fd_set *readset) { Buffer m; Channel *c; - int client_fd, new_fd[3], ver, allowed; + int client_fd, new_fd[3], ver, allowed, window, packetmax; socklen_t addrlen; struct sockaddr_storage addr; struct confirm_ctx *cctx; @@ -900,9 +900,15 @@ client_process_control(fd_set *readset) set_nonblock(client_fd); + window = CHAN_SES_WINDOW_DEFAULT; + packetmax = CHAN_SES_PACKET_DEFAULT; + if (cctx->want_tty) { + window >>= 1; + packetmax >>= 1; + } + c = channel_new("session", SSH_CHANNEL_OPENING, - new_fd[0], new_fd[1], new_fd[2], - CHAN_SES_WINDOW_DEFAULT, CHAN_SES_PACKET_DEFAULT, + new_fd[0], new_fd[1], new_fd[2], window, packetmax, CHAN_EXTENDED_WRITE, "client-session", /*nonblock*/0); /* XXX */ @@ -1757,7 +1763,7 @@ client_request_agent(const char *request_type, int rchan) error("Warning: this is probably a break-in attempt by a malicious server."); return NULL; } - sock = ssh_get_authentication_socket(); + sock = ssh_get_authentication_socket(); if (sock < 0) return NULL; c = channel_new("authentication agent connection", |