Patch to improve afs support
Booker C. Bense
bbense at networking.stanford.edu
Tue Oct 9 14:20:03 EST 2001
On Mon, 8 Oct 2001 mouring at etoh.eviladmin.org wrote:
>
> Please submit all patches in unifed format.
>
> - Ben
>
Index: session.c
===================================================================
RCS file: /afs/ir/dev/cvs/kerberos/openssh/session.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- session.c 2001/10/01 18:18:47 1.1
+++ session.c 2001/10/08 20:54:01 1.2
@@ -1343,15 +1343,6 @@
for (i = 3; i < 64; i++)
close(i);
- /* Change current directory to the user\'s home directory. */
- if (chdir(pw->pw_dir) < 0) {
- fprintf(stderr, "Could not chdir to home directory %s: %s\n",
- pw->pw_dir, strerror(errno));
-#ifdef HAVE_LOGIN_CAP
- if (login_getcapbool(lc, "requirehome", 0))
- exit(1);
-#endif
- }
/*
* Must take new environment into use so that .ssh/rc, /etc/sshrc and
@@ -1370,6 +1361,17 @@
krb_afslog(0, 0);
}
#endif /* AFS */
+
+ /* Change current directory to the user\'s home directory. */
+ if (chdir(pw->pw_dir) < 0) {
+ fprintf(stderr, "Could not chdir to home directory %s: %s\n",
+ pw->pw_dir, strerror(errno));
+#ifdef HAVE_LOGIN_CAP
+ if (login_getcapbool(lc, "requirehome", 0))
+ exit(1);
+#endif
+ }
+
/*
* Run $HOME/.ssh/rc, /etc/sshrc, or xauth (whichever is found first
More information about the openssh-unix-dev
mailing list