summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sshconnect.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sshconnect.c b/sshconnect.c
index fdcdcd855..103d84e38 100644
--- a/sshconnect.c
+++ b/sshconnect.c
@@ -257,7 +257,7 @@ ssh_proxy_connect(struct ssh *ssh, const char *host, u_short port,
257 /* Execute the proxy command. Note that we gave up any 257 /* Execute the proxy command. Note that we gave up any
258 extra privileges above. */ 258 extra privileges above. */
259 signal(SIGPIPE, SIG_DFL); 259 signal(SIGPIPE, SIG_DFL);
260 execv(argv[0], argv); 260 execvp(argv[0], argv);
261 perror(argv[0]); 261 perror(argv[0]);
262 exit(1); 262 exit(1);
263 } 263 }
@@ -1382,7 +1382,7 @@ ssh_local_cmd(const char *args)
1382 if (pid == 0) { 1382 if (pid == 0) {
1383 signal(SIGPIPE, SIG_DFL); 1383 signal(SIGPIPE, SIG_DFL);
1384 debug3("Executing %s -c \"%s\"", shell, args); 1384 debug3("Executing %s -c \"%s\"", shell, args);
1385 execl(shell, shell, "-c", args, (char *)NULL); 1385 execlp(shell, shell, "-c", args, (char *)NULL);
1386 error("Couldn't execute %s -c \"%s\": %s", 1386 error("Couldn't execute %s -c \"%s\": %s",
1387 shell, args, strerror(errno)); 1387 shell, args, strerror(errno));
1388 _exit(1); 1388 _exit(1);