diff options
author | Damien Miller <djm@cvs.openbsd.org> | 2004-05-26 08:59:58 +0000 |
---|---|---|
committer | Damien Miller <djm@cvs.openbsd.org> | 2004-05-26 08:59:58 +0000 |
commit | 592f3deb9498af1a8bf1de4b779ea6610db78a76 (patch) | |
tree | 100a18d2a5ba2ff96b532b9b32c2cf6da16856c2 /usr.bin/ssh | |
parent | ee5735a919b61d1deb0828878c5708855f007e5a (diff) |
exit -> _exit in forked child on error; from andrushock AT korovino.net
Diffstat (limited to 'usr.bin/ssh')
-rw-r--r-- | usr.bin/ssh/sftp.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/ssh/sftp.c b/usr.bin/ssh/sftp.c index 443d3ffc79a..941922bae36 100644 --- a/usr.bin/ssh/sftp.c +++ b/usr.bin/ssh/sftp.c @@ -16,7 +16,7 @@ #include "includes.h" -RCSID("$OpenBSD: sftp.c,v 1.46 2004/05/19 12:17:33 djm Exp $"); +RCSID("$OpenBSD: sftp.c,v 1.47 2004/05/26 08:59:57 djm Exp $"); #include <glob.h> @@ -1256,7 +1256,7 @@ connect_to_server(char *path, char **args, int *in, int *out) if ((dup2(c_in, STDIN_FILENO) == -1) || (dup2(c_out, STDOUT_FILENO) == -1)) { fprintf(stderr, "dup2: %s\n", strerror(errno)); - exit(1); + _exit(1); } close(*in); close(*out); @@ -1272,7 +1272,7 @@ connect_to_server(char *path, char **args, int *in, int *out) signal(SIGINT, SIG_IGN); execv(path, args); fprintf(stderr, "exec: %s: %s\n", path, strerror(errno)); - exit(1); + _exit(1); } signal(SIGTERM, killchild); |