aboutsummaryrefslogtreecommitdiff
path: root/bastion/proxy.c
diff options
context:
space:
mode:
Diffstat (limited to 'bastion/proxy.c')
-rw-r--r--bastion/proxy.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/bastion/proxy.c b/bastion/proxy.c
index 7fbf816..f608d31 100644
--- a/bastion/proxy.c
+++ b/bastion/proxy.c
@@ -210,10 +210,10 @@ void handle_proxy_session(ssh_event event, ssh_session session, ssh_channel my_c
break;
}
} while(ssh_channel_is_open(my_channel) && ssh_channel_is_open(pdata.client_channel));
- if (ssh_channel_is_open(my_channel))
- ssh_channel_close(my_channel);
if (ssh_channel_is_open(cdata->my_channel))
ssh_channel_close(cdata->my_channel);
+ if (ssh_channel_is_open(my_channel))
+ ssh_channel_close(my_channel);
client_cleanup(cdata);
}