File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1- /* $OpenBSD: ssh.c,v 1.618 2025/09/15 04:50:42 djm Exp $ */
1+ /* $OpenBSD: ssh.c,v 1.619 2025/09/25 07:05:11 djm Exp $ */
22/*
33 * Author: Tatu Ylonen <ylo@cs.hut.fi>
44 * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
@@ -1725,8 +1725,6 @@ main(int ac, char **av)
17251725 & timeout_ms , options .tcp_keep_alive ) != 0 )
17261726 exit (255 );
17271727
1728- if (addrs != NULL )
1729- freeaddrinfo (addrs );
17301728
17311729 ssh_packet_set_timeout (ssh , options .server_alive_interval ,
17321730 options .server_alive_count_max );
@@ -1867,9 +1865,13 @@ main(int ac, char **av)
18671865#endif
18681866
18691867 skip_connect :
1868+ if (addrs != NULL )
1869+ freeaddrinfo (addrs );
18701870 exit_status = ssh_session2 (ssh , cinfo );
18711871 ssh_conn_info_free (cinfo );
1872- ssh_packet_close (ssh );
1872+ channel_free_channels (ssh );
1873+ ssh_packet_free (ssh );
1874+ pwfree (pw );
18731875
18741876 if (options .control_path != NULL && muxserver_sock != -1 )
18751877 unlink (options .control_path );
You can’t perform that action at this time.
0 commit comments