# HG changeset patch # User Matt Johnston # Date 1438607843 -28800 # Node ID cc3916a7afd9741cc771b77de08fbc012d0025df # Parent 40434003bd9664f86e6dbba3074c1a4c0fcff0ca increase MAX_CMD_LEN to 9000 diff -r 40434003bd96 -r cc3916a7afd9 sysoptions.h --- a/sysoptions.h Mon Aug 03 21:05:42 2015 +0800 +++ b/sysoptions.h Mon Aug 03 21:17:23 2015 +0800 @@ -47,7 +47,7 @@ * the clearenv() function */ #define ENV_SIZE 100 -#define MAX_CMD_LEN 1024 /* max length of a command */ +#define MAX_CMD_LEN 9000 /* max length of a command */ #define MAX_TERM_LEN 200 /* max length of TERM name */ #define MAX_HOST_LEN 254 /* max hostname len for tcp fwding */ @@ -153,7 +153,8 @@ #define MAX_CHANNELS 100 /* simple mem restriction, includes each tcp/x11 connection, so can't be _too_ small */ -#define MAX_STRING_LEN 2400 /* Sun SSH needs this long for algos */ +#define MAX_STRING_LEN (MAX(MAX_CMD_LEN, 2400)) /* Sun SSH needs 2400 for algos, + MAX_CMD_LEN is usually longer */ /* For a 4096 bit DSS key, empirically determined */ #define MAX_PUBKEY_SIZE 1700