]> andersk Git - openssh.git/commitdiff
- (dtucker) [clientloop.c configure.ac defines.h] Make the client's IO buffer
authordtucker <dtucker>
Fri, 28 Aug 2009 01:21:06 +0000 (01:21 +0000)
committerdtucker <dtucker>
Fri, 28 Aug 2009 01:21:06 +0000 (01:21 +0000)
   size a compile-time option and set it to 64k on Cygwin, since Corinna
   reports that it makes a significant difference to performance.  ok djm@

ChangeLog
clientloop.c
configure.ac
defines.h

index e24f732747debdacb6ae447789518db8856d1f10..89bfa66a139e2f48967461681ac5610b4d3791eb 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -12,6 +12,9 @@
     the pty master on Solaris, since it never succeeds and can hang if large
     amounts of data is sent to the slave (eg a copy-paste).  Based on a patch
     originally from Doke Scott, ok djm@
+ - (dtucker) [clientloop.c configure.ac defines.h] Make the client's IO buffer
+   size a compile-time option and set it to 64k on Cygwin, since Corinna
+   reports that it makes a significant difference to performance.  ok djm@
 
 20090820
  - (dtucker) [includes.h] Bug #1634: do not include system glob.h if we're not
index b8352f6bf2b96f46b8ad67cc707d09a8e2e2a5a0..9a7dc0ab0b01ba9b58848bb6dce0cbbbfcfb085e 100644 (file)
@@ -636,7 +636,7 @@ static void
 client_process_net_input(fd_set *readset)
 {
        int len, cont = 0;
-       char buf[8192];
+       char buf[SSH_IOBUFSZ];
 
        /*
         * Read input from the server, and add any such data to the buffer of
@@ -1129,7 +1129,7 @@ static void
 client_process_input(fd_set *readset)
 {
        int len;
-       char buf[8192];
+       char buf[SSH_IOBUFSZ];
 
        /* Read input from stdin. */
        if (FD_ISSET(fileno(stdin), readset)) {
index 9524d5c34cb0a86c6620468ec81b163fc875e29a..a2566a2b9fe1977a87d41256f72a2ae6f9275b97 100644 (file)
@@ -446,6 +446,7 @@ int main(void) { exit(0); }
        AC_DEFINE(DISABLE_FD_PASSING, 1,
                [Define if your platform needs to skip post auth
                file descriptor passing])
+       AC_DEFINE(SSH_IOBUFSZ, 65536, [Windows is sensitive to read buffer size])
        ;;
 *-*-dgux*)
        AC_DEFINE(IP_TOS_IS_BROKEN, 1,
index dc25cdc3e80efef03625a0dedff862e2c2757d6a..2412fdfd729f3cf3a69a28426bd42b99fab54720 100644 (file)
--- a/defines.h
+++ b/defines.h
@@ -749,4 +749,8 @@ struct winsize {
 #define INET6_ADDRSTRLEN 46
 #endif
 
+#ifndef SSH_IOBUFSZ
+# define SSH_IOBUFSZ 8192
+#endif
+
 #endif /* _DEFINES_H */
This page took 0.765111 seconds and 5 git commands to generate.