summaryrefslogtreecommitdiff
path: root/ssh.c
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2010-10-07 22:07:32 +1100
committerDamien Miller <djm@mindrot.org>2010-10-07 22:07:32 +1100
commita41ccca643364b3b1b65d7a818577dd35360fa20 (patch)
treecfcd6f4c1696af7bc514e6835d08d6ccbcfb8974 /ssh.c
parent38d9a965bfc795fba1c000e0b42e705e2bcd34c9 (diff)
- djm@cvs.openbsd.org 2010/10/06 06:39:28
[clientloop.c ssh.c sshconnect.c sshconnect.h] kill proxy command on fatal() (we already kill it on clean exit); ok markus@
Diffstat (limited to 'ssh.c')
-rw-r--r--ssh.c13
1 files changed, 3 insertions, 10 deletions
diff --git a/ssh.c b/ssh.c
index 20de28a64..7632cf51e 100644
--- a/ssh.c
+++ b/ssh.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: ssh.c,v 1.352 2010/09/20 04:41:47 djm Exp $ */ 1/* $OpenBSD: ssh.c,v 1.353 2010/10/06 06:39:28 djm 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
@@ -183,9 +183,6 @@ int subsystem_flag = 0;
183/* # of replies received for global requests */ 183/* # of replies received for global requests */
184static int remote_forward_confirms_received = 0; 184static int remote_forward_confirms_received = 0;
185 185
186/* pid of proxycommand child process */
187pid_t proxy_command_pid = 0;
188
189/* mux.c */ 186/* mux.c */
190extern int muxserver_sock; 187extern int muxserver_sock;
191extern u_int muxclient_command; 188extern u_int muxclient_command;
@@ -921,12 +918,8 @@ main(int ac, char **av)
921 if (options.control_path != NULL && muxserver_sock != -1) 918 if (options.control_path != NULL && muxserver_sock != -1)
922 unlink(options.control_path); 919 unlink(options.control_path);
923 920
924 /* 921 /* Kill ProxyCommand if it is running. */
925 * Send SIGHUP to proxy command if used. We don't wait() in 922 ssh_kill_proxy_command();
926 * case it hangs and instead rely on init to reap the child
927 */
928 if (proxy_command_pid > 1)
929 kill(proxy_command_pid, SIGHUP);
930 923
931 return exit_status; 924 return exit_status;
932} 925}