diff --git a/ChangeLog b/ChangeLog index 231e7c9d..a636ba3b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2008-05-26 Nicolas François + + * libmisc/setupenv.c: Avoid implicit conversion of chars to + booleans. + 2008-05-26 Nicolas François * libmisc/copydir.c: selinux_checked, selinux_enabled, and set_orig diff --git a/libmisc/setupenv.c b/libmisc/setupenv.c index 8147d1d0..8eb383d0 100644 --- a/libmisc/setupenv.c +++ b/libmisc/setupenv.c @@ -229,7 +229,7 @@ void setup_env (struct passwd *info) * Create the SHELL environmental variable and export it. */ - if (info->pw_shell == (char *) 0 || !*info->pw_shell) { + if ((NULL == info->pw_shell) || ('\0' == *info->pw_shell)) { static char temp_pw_shell[] = "/bin/sh"; info->pw_shell = temp_pw_shell;