summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormarkus <markus@openbsd.org>2001-09-16 14:46:54 +0000
committermarkus <markus@openbsd.org>2001-09-16 14:46:54 +0000
commita94c3b44656bdc2cbcd426f165a9e73fc0eaac6c (patch)
tree93babb8dacb863af9618d1f406c7cd760abfebfb
parentAdd a manual page for genassym.sh, from NetBSD. (diff)
downloadwireguard-openbsd-a94c3b44656bdc2cbcd426f165a9e73fc0eaac6c.tar.xz
wireguard-openbsd-a94c3b44656bdc2cbcd426f165a9e73fc0eaac6c.zip
calls krb_afslog() after setting $HOME; mattiasa@e.kth.se; fixes pr 1943
-rw-r--r--usr.bin/ssh/session.c26
1 files changed, 13 insertions, 13 deletions
diff --git a/usr.bin/ssh/session.c b/usr.bin/ssh/session.c
index f810d594214..2431470fd4f 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.101 2001/09/14 18:59:11 markus Exp $");
+RCSID("$OpenBSD: session.c,v 1.102 2001/09/16 14:46:54 markus Exp $");
#include "ssh.h"
#include "ssh1.h"
@@ -851,18 +851,6 @@ do_child(Session *s, const char *command)
shell = login_getcapstr(lc, "shell", (char *)shell, (char *)shell);
#endif
-#ifdef AFS
- /* Try to get AFS tokens for the local cell. */
- if (k_hasafs()) {
- char cell[64];
-
- if (k_afs_cell_of_file(pw->pw_dir, cell, sizeof(cell)) == 0)
- krb_afslog(cell, 0);
-
- krb_afslog(0, 0);
- }
-#endif /* AFS */
-
/* Initialize the environment. */
envsize = 100;
env = xmalloc(envsize * sizeof(char *));
@@ -999,6 +987,18 @@ do_child(Session *s, const char *command)
*/
environ = env;
+#ifdef AFS
+ /* Try to get AFS tokens for the local cell. */
+ if (k_hasafs()) {
+ char cell[64];
+
+ if (k_afs_cell_of_file(pw->pw_dir, cell, sizeof(cell)) == 0)
+ krb_afslog(cell, 0);
+
+ krb_afslog(0, 0);
+ }
+#endif /* AFS */
+
/*
* Run $HOME/.ssh/rc, /etc/sshrc, or xauth (whichever is found first
* in this order).