summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Lindstrom <mouring@eviladmin.org>2001-05-03 22:37:26 +0000
committerBen Lindstrom <mouring@eviladmin.org>2001-05-03 22:37:26 +0000
commit60402fd42a6305f1df1de9269ba1654f02fe1309 (patch)
tree2d3a359e3eb4208abd74212396b46cad24248ff2
parent2b45180b2e743302ec502737fcd8abce4397f82d (diff)
- markus@cvs.openbsd.org 2001/05/03 15:45:15
[session.c] exec shell -c /bin/sh .ssh/sshrc, from abartlet@pcug.org.au
-rw-r--r--ChangeLog5
-rw-r--r--session.c9
2 files changed, 9 insertions, 5 deletions
diff --git a/ChangeLog b/ChangeLog
index 10488fed..de8f3647 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -3,6 +3,9 @@
- stevesk@cvs.openbsd.org 2001/05/03 15:07:39
[channels.c]
typo in debug() string
+ - markus@cvs.openbsd.org 2001/05/03 15:45:15
+ [session.c]
+ exec shell -c /bin/sh .ssh/sshrc, from abartlet@pcug.org.au
20010503
- OpenBSD CVS Sync
@@ -5314,4 +5317,4 @@
- Wrote replacements for strlcpy and mkdtemp
- Released 1.0pre1
-$Id: ChangeLog,v 1.1191 2001/05/03 22:35:32 mouring Exp $
+$Id: ChangeLog,v 1.1192 2001/05/03 22:37:26 mouring Exp $
diff --git a/session.c b/session.c
index 3960c9f2..bb98176b 100644
--- a/session.c
+++ b/session.c
@@ -33,7 +33,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: session.c,v 1.74 2001/04/17 19:34:25 markus Exp $");
+RCSID("$OpenBSD: session.c,v 1.75 2001/05/03 15:45:15 markus Exp $");
#include "ssh.h"
#include "ssh1.h"
@@ -1393,10 +1393,11 @@ do_child(Session *s, const char *command)
if (!options.use_login) {
/* ignore _PATH_SSH_USER_RC for subsystems */
if (!s->is_subsystem && (stat(_PATH_SSH_USER_RC, &st) >= 0)) {
+ snprintf(cmd, sizeof cmd, "%s -c '%s %s'",
+ shell, _PATH_BSHELL, _PATH_SSH_USER_RC);
if (debug_flag)
- fprintf(stderr, "Running %s %s\n", _PATH_BSHELL,
- _PATH_SSH_USER_RC);
- f = popen(_PATH_BSHELL " " _PATH_SSH_USER_RC, "w");
+ fprintf(stderr, "Running %s\n", cmd);
+ f = popen(cmd, "w");
if (f) {
if (do_xauth)
fprintf(f, "%s %s\n", s->auth_proto,