summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--usr.bin/ssh/session.c10
-rw-r--r--usr.bin/ssh/sshconnect.c8
2 files changed, 9 insertions, 9 deletions
diff --git a/usr.bin/ssh/session.c b/usr.bin/ssh/session.c
index d3c20fcee9e..48028a6f662 100644
--- a/usr.bin/ssh/session.c
+++ b/usr.bin/ssh/session.c
@@ -33,7 +33,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: session.c,v 1.45 2000/12/19 23:17:58 markus Exp $");
+RCSID("$OpenBSD: session.c,v 1.46 2001/01/04 22:41:03 markus Exp $");
#include "xmalloc.h"
#include "ssh.h"
@@ -1014,9 +1014,9 @@ do_child(const char *command, struct passwd * pw, const char *term,
if (!options.use_login) {
if (stat(SSH_USER_RC, &st) >= 0) {
if (debug_flag)
- fprintf(stderr, "Running /bin/sh %s\n", SSH_USER_RC);
+ fprintf(stderr, "Running %s %s\n", _PATH_BSHELL, SSH_USER_RC);
- f = popen("/bin/sh " SSH_USER_RC, "w");
+ f = popen(_PATH_BSHELL " " SSH_USER_RC, "w");
if (f) {
if (auth_proto != NULL && auth_data != NULL)
fprintf(f, "%s %s\n", auth_proto, auth_data);
@@ -1025,9 +1025,9 @@ do_child(const char *command, struct passwd * pw, const char *term,
fprintf(stderr, "Could not run %s\n", SSH_USER_RC);
} else if (stat(SSH_SYSTEM_RC, &st) >= 0) {
if (debug_flag)
- fprintf(stderr, "Running /bin/sh %s\n", SSH_SYSTEM_RC);
+ fprintf(stderr, "Running %s %s\n", _PATH_BSHELL, SSH_SYSTEM_RC);
- f = popen("/bin/sh " SSH_SYSTEM_RC, "w");
+ f = popen(_PATH_BSHELL " " SSH_SYSTEM_RC, "w");
if (f) {
if (auth_proto != NULL && auth_data != NULL)
fprintf(f, "%s %s\n", auth_proto, auth_data);
diff --git a/usr.bin/ssh/sshconnect.c b/usr.bin/ssh/sshconnect.c
index 950cfe2c375..e4c8c92697e 100644
--- a/usr.bin/ssh/sshconnect.c
+++ b/usr.bin/ssh/sshconnect.c
@@ -13,7 +13,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: sshconnect.c,v 1.88 2001/01/02 20:50:56 markus Exp $");
+RCSID("$OpenBSD: sshconnect.c,v 1.89 2001/01/04 22:41:03 markus Exp $");
#include <openssl/bn.h>
#include <openssl/dsa.h>
@@ -109,15 +109,15 @@ ssh_proxy_connect(const char *host, u_short port, uid_t original_real_uid,
/* Stderr is left as it is so that error messages get
printed on the user's terminal. */
- argv[0] = "/bin/sh";
+ argv[0] = _PATH_BSHELL;
argv[1] = "-c";
argv[2] = command_string;
argv[3] = NULL;
/* Execute the proxy command. Note that we gave up any
extra privileges above. */
- execv("/bin/sh", argv);
- perror("/bin/sh");
+ execv(argv[0], argv);
+ perror(argv[0]);
exit(1);
}
/* Parent. */