Nice long file name for a patch...
>From 81aaa0b985d80a097cba316a583eac5336ed3028 Mon Sep 17 00:00:00 2001
From: Jakob Kramer <[email protected]>
Date: Fri, 18 Oct 2013 21:57:24 +0200
Subject: [PATCH] fix SHELL being set to the usr's home directory
---
su.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/su.c b/su.c
index 94ead18..339cba1 100644
--- a/su.c
+++ b/su.c
@@ -106,7 +106,7 @@ main(int argc, char **argv)
newargv = (char *const[]){pw->pw_shell, NULL};
if (!pflag) {
setenv("HOME", pw->pw_dir, 1);
- setenv("SHELL", pw->pw_dir, 1);
+ setenv("SHELL", pw->pw_shell, 1);
if (strcmp(pw->pw_name, "root") != 0) {
setenv("USER", pw->pw_name, 1);
setenv("LOGNAME", pw->pw_name, 1);
--
1.8.1.2