diff options
author | Damien Miller <djm@mindrot.org> | 2002-02-19 15:20:08 +1100 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2002-02-19 15:20:08 +1100 |
commit | 2aa0c1995c1a4c138b7a03fe90e75d6f73eab1f3 (patch) | |
tree | cbea3712156ea475df53e32984af4fce390c94d9 | |
parent | 7af3d10588830daeb31f1d53663df95bad26356c (diff) |
- markus@cvs.openbsd.org 2002/02/14 23:27:59
[channels.c]
increase the SSH v2 window size to 4 packets. comsumes a little
bit more memory for slow receivers but increases througput.
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | channels.c | 7 |
2 files changed, 8 insertions, 5 deletions
@@ -5,6 +5,10 @@ | |||
5 | When you give command examples and etc., in a manual page prefix them with: $ command | 5 | When you give command examples and etc., in a manual page prefix them with: $ command |
6 | or | 6 | or |
7 | # command | 7 | # command |
8 | - markus@cvs.openbsd.org 2002/02/14 23:27:59 | ||
9 | [channels.c] | ||
10 | increase the SSH v2 window size to 4 packets. comsumes a little | ||
11 | bit more memory for slow receivers but increases througput. | ||
8 | 12 | ||
9 | 20020218 | 13 | 20020218 |
10 | - (tim) newer config.guess from ftp://ftp.gnu.org/gnu/config/config.guess | 14 | - (tim) newer config.guess from ftp://ftp.gnu.org/gnu/config/config.guess |
@@ -7602,4 +7606,4 @@ | |||
7602 | - Wrote replacements for strlcpy and mkdtemp | 7606 | - Wrote replacements for strlcpy and mkdtemp |
7603 | - Released 1.0pre1 | 7607 | - Released 1.0pre1 |
7604 | 7608 | ||
7605 | $Id: ChangeLog,v 1.1855 2002/02/19 04:19:42 djm Exp $ | 7609 | $Id: ChangeLog,v 1.1856 2002/02/19 04:20:08 djm Exp $ |
diff --git a/channels.c b/channels.c index 7da46143f..50d6f16ad 100644 --- a/channels.c +++ b/channels.c | |||
@@ -39,7 +39,7 @@ | |||
39 | */ | 39 | */ |
40 | 40 | ||
41 | #include "includes.h" | 41 | #include "includes.h" |
42 | RCSID("$OpenBSD: channels.c,v 1.167 2002/02/06 14:55:15 markus Exp $"); | 42 | RCSID("$OpenBSD: channels.c,v 1.168 2002/02/14 23:27:59 markus Exp $"); |
43 | 43 | ||
44 | #include "ssh.h" | 44 | #include "ssh.h" |
45 | #include "ssh1.h" | 45 | #include "ssh1.h" |
@@ -644,15 +644,14 @@ channel_register_filter(int id, channel_filter_fn *fn) | |||
644 | 644 | ||
645 | void | 645 | void |
646 | channel_set_fds(int id, int rfd, int wfd, int efd, | 646 | channel_set_fds(int id, int rfd, int wfd, int efd, |
647 | int extusage, int nonblock) | 647 | int extusage, int nonblock, u_int window_max) |
648 | { | 648 | { |
649 | Channel *c = channel_lookup(id); | 649 | Channel *c = channel_lookup(id); |
650 | if (c == NULL || c->type != SSH_CHANNEL_LARVAL) | 650 | if (c == NULL || c->type != SSH_CHANNEL_LARVAL) |
651 | fatal("channel_activate for non-larval channel %d.", id); | 651 | fatal("channel_activate for non-larval channel %d.", id); |
652 | channel_register_fds(c, rfd, wfd, efd, extusage, nonblock); | 652 | channel_register_fds(c, rfd, wfd, efd, extusage, nonblock); |
653 | c->type = SSH_CHANNEL_OPEN; | 653 | c->type = SSH_CHANNEL_OPEN; |
654 | /* XXX window size? */ | 654 | c->local_window = c->local_window_max = window_max; |
655 | c->local_window = c->local_window_max = c->local_maxpacket * 2; | ||
656 | packet_start(SSH2_MSG_CHANNEL_WINDOW_ADJUST); | 655 | packet_start(SSH2_MSG_CHANNEL_WINDOW_ADJUST); |
657 | packet_put_int(c->remote_id); | 656 | packet_put_int(c->remote_id); |
658 | packet_put_int(c->local_window); | 657 | packet_put_int(c->local_window); |