Index: sftp.c
===================================================================
RCS file: /usr/local/src/security/openssh/cvs/openssh_cvs/sftp.c,v
retrieving revision 1.61
diff -u -p -r1.61 sftp.c
--- sftp.c	6 Dec 2004 11:45:54 -0000	1.61
+++ sftp.c	7 Dec 2004 01:35:51 -0000
@@ -150,8 +150,10 @@ int interactive_loop(int fd_in, int fd_o
 static void
 killchild(int signo)
 {
-	if (sshpid > 1)
+	if (sshpid > 1) {
 		kill(sshpid, SIGTERM);
+		waitpid(sshpid, NULL, 0);
+	}
 
 	_exit(1);
 }
Index: scp.c
===================================================================
RCS file: /usr/local/src/security/openssh/cvs/openssh_cvs/scp.c,v
retrieving revision 1.131
diff -u -p -r1.131 scp.c
--- scp.c	5 Nov 2004 09:10:02 -0000	1.131
+++ scp.c	7 Dec 2004 01:25:55 -0000
@@ -108,8 +108,10 @@ pid_t do_cmd_pid = -1;
 static void
 killchild(int signo)
 {
-	if (do_cmd_pid > 1)
+	if (do_cmd_pid > 1) {
 		kill(do_cmd_pid, signo);
+		waitpid(do_cmd_pid, NULL, 0);
+	}
 
 	_exit(1);
 }
