summaryrefslogtreecommitdiff
path: root/packet.c
diff options
context:
space:
mode:
authormarkus@openbsd.org <markus@openbsd.org>2020-06-24 15:10:38 +0000
committerDamien Miller <djm@mindrot.org>2020-06-26 15:18:44 +1000
commite35995088cd6691a712bfd586bae8084a3a922ba (patch)
tree623a1f22e8dcba32af0c055be57e6c1654fdee70 /packet.c
parent250246fef22b87a54a63211c60a2def9be431fbd (diff)
upstream: fix ssh -O proxy w/mux which got broken by no longer
making ssh->kex optional in packet.c revision 1.278 ok djm@ OpenBSD-Commit-ID: 2b65df04a064c2c6277359921d2320c90ab7d917
Diffstat (limited to 'packet.c')
-rw-r--r--packet.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/packet.c b/packet.c
index e7abb3416..4cce4133a 100644
--- a/packet.c
+++ b/packet.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: packet.c,v 1.291 2020/03/06 18:20:44 markus Exp $ */ 1/* $OpenBSD: packet.c,v 1.292 2020/06/24 15:10:38 markus Exp $ */
2/* 2/*
3 * Author: Tatu Ylonen <ylo@cs.hut.fi> 3 * Author: Tatu Ylonen <ylo@cs.hut.fi>
4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland 4 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -282,7 +282,8 @@ ssh_packet_set_input_hook(struct ssh *ssh, ssh_packet_hook_fn *hook, void *ctx)
282int 282int
283ssh_packet_is_rekeying(struct ssh *ssh) 283ssh_packet_is_rekeying(struct ssh *ssh)
284{ 284{
285 return ssh->state->rekeying || ssh->kex->done == 0; 285 return ssh->state->rekeying ||
286 (ssh->kex != NULL && ssh->kex->done == 0);
286} 287}
287 288
288/* 289/*
@@ -345,6 +346,8 @@ ssh_packet_set_mux(struct ssh *ssh)
345{ 346{
346 ssh->state->mux = 1; 347 ssh->state->mux = 1;
347 ssh->state->rekeying = 0; 348 ssh->state->rekeying = 0;
349 kex_free(ssh->kex);
350 ssh->kex = NULL;
348} 351}
349 352
350int 353int