diff options
author | Damien Miller <djm@cvs.openbsd.org> | 2015-04-07 23:00:43 +0000 |
---|---|---|
committer | Damien Miller <djm@cvs.openbsd.org> | 2015-04-07 23:00:43 +0000 |
commit | 47aaddf4650438695425219483a930b11b02a03e (patch) | |
tree | 7120984e26c6528d9d763372e5cf5bf0dfd0e3a2 | |
parent | da85c8f5958ac2552c5f99ba8d2f8250e223dc74 (diff) |
treat Protocol=1,2|2,1 as Protocol=2 when compiled without SSH1
support; ok dtucker@ millert@
-rw-r--r-- | usr.bin/ssh/compat.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/usr.bin/ssh/compat.c b/usr.bin/ssh/compat.c index 5eb9e95d1ae..c8b01a135e2 100644 --- a/usr.bin/ssh/compat.c +++ b/usr.bin/ssh/compat.c @@ -1,4 +1,4 @@ -/* $OpenBSD: compat.c,v 1.87 2015/01/19 20:20:20 markus Exp $ */ +/* $OpenBSD: compat.c,v 1.88 2015/04/07 23:00:42 djm Exp $ */ /* * Copyright (c) 1999, 2000, 2001, 2002 Markus Friedl. All rights reserved. * @@ -197,9 +197,11 @@ proto_spec(const char *spec) for ((p = strsep(&q, SEP)); p && *p != '\0'; (p = strsep(&q, SEP))) { switch (atoi(p)) { case 1: +#ifdef WITH_SSH1 if (ret == SSH_PROTO_UNKNOWN) ret |= SSH_PROTO_1_PREFERRED; ret |= SSH_PROTO_1; +#endif break; case 2: ret |= SSH_PROTO_2; |