From 427b60f2885a93201752cd48d029cb7acace3b04 Mon Sep 17 00:00:00 2001 From: nekral-guest Date: Tue, 30 Mar 2010 21:32:36 +0000 Subject: [PATCH] * src/su.c: shell's name must be -su when a su fakes a login. --- ChangeLog | 4 ++++ src/su.c | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index fbb37653..872f24d3 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2010-03-30 Nicolas François + + * src/su.c: shell's name must be -su when a su fakes a login. + 2010-03-30 Nicolas François * NEWS, configure.in, libmisc/copydir.c, man/useradd.8.xml, diff --git a/src/su.c b/src/su.c index 837e76c3..a844edc8 100644 --- a/src/su.c +++ b/src/su.c @@ -1021,7 +1021,7 @@ int main (int argc, char **argv) * Use the shell and create an argv * with the rest of the command line included. */ - argv[-1] = shellstr; + argv[-1] = cp; #ifndef USE_PAM execve_shell (shellstr, &argv[-1], environ); err = errno;