aboutsummaryrefslogtreecommitdiff
path: root/channels.c
diff options
context:
space:
mode:
authorEd Maste <emaste@FreeBSD.org>2021-11-04 17:16:52 +0000
committerEd Maste <emaste@FreeBSD.org>2021-11-04 17:16:52 +0000
commit4f19900354cc6b4531038e294d8ad1d115118e9d (patch)
tree50a787995c8ed3d824f4d8a690bb9cd26a7f5e3e /channels.c
parent66719ee573ac2290622db642f6e89ab35b179f3d (diff)
downloadsrc-4f19900354cc6b4531038e294d8ad1d115118e9d.tar.gz
src-4f19900354cc6b4531038e294d8ad1d115118e9d.zip
Vendor import of OpenSSH 8.8p1vendor/openssh/8.8p1
Diffstat (limited to 'channels.c')
-rw-r--r--channels.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/channels.c b/channels.c
index fd72f371df98..1c714c845e18 100644
--- a/channels.c
+++ b/channels.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: channels.c,v 1.407 2021/05/19 01:24:05 djm Exp $ */
+/* $OpenBSD: channels.c,v 1.408 2021/09/14 11:04:21 mbuhl Exp $ */
/*
* Author: Tatu Ylonen <ylo@cs.hut.fi>
* Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -629,9 +629,11 @@ channel_free(struct ssh *ssh, Channel *c)
debug("channel %d: free: %s, nchannels %u", c->self,
c->remote_name ? c->remote_name : "???", n);
- if (c->type == SSH_CHANNEL_MUX_CLIENT)
+ if (c->type == SSH_CHANNEL_MUX_CLIENT) {
mux_remove_remote_forwardings(ssh, c);
- else if (c->type == SSH_CHANNEL_MUX_LISTENER) {
+ free(c->mux_ctx);
+ c->mux_ctx = NULL;
+ } else if (c->type == SSH_CHANNEL_MUX_LISTENER) {
free(c->mux_ctx);
c->mux_ctx = NULL;
}