Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions autogen.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ CFLAGS="$CFLAGS -Werror=int-conversion"
CFLAGS="$CFLAGS -Werror=sign-compare"
CFLAGS="$CFLAGS -Werror=sizeof-pointer-div"
CFLAGS="$CFLAGS -Werror=unused-but-set-parameter"
CFLAGS="$CFLAGS -Werror=unused-but-set-variable"
CFLAGS="$CFLAGS -Werror=unused-function"
CFLAGS="$CFLAGS -Werror=unused-label"
CFLAGS="$CFLAGS -Werror=unused-local-typedefs"
Expand Down
4 changes: 4 additions & 0 deletions src/login.c
Original file line number Diff line number Diff line change
Expand Up @@ -451,7 +451,9 @@ static /*@observer@*/const char *get_failent_user (/*@returned@*/const char *use
int main (int argc, char **argv)
{
int err;
#if !defined(USE_PAM)
bool subroot = false;
#endif
char **envp = environ;
char *host = NULL;
char tty[BUFSIZ];
Expand Down Expand Up @@ -1023,7 +1025,9 @@ int main (int argc, char **argv)
if (strprefix(pwd->pw_shell, "*")) { /* subsystem root */
pwd->pw_shell++; /* skip the '*' */
subsystem (pwd); /* figure out what to execute */
#if !defined(USE_PAM)
subroot = true; /* say I was here again */
#endif
endpwent (); /* close all of the file which were */
endgrent (); /* open in the original rooted file */
endspent (); /* system. they will be re-opened */
Expand Down
8 changes: 4 additions & 4 deletions src/useradd.c
Original file line number Diff line number Diff line change
Expand Up @@ -2340,17 +2340,17 @@ static void create_home(const struct option_flags *flags)
* exist. It will be created mode 660 owned by the user and group
* 'mail'
*/
static void create_mail(const struct option_flags *flags)
static void create_mail(MAYBE_UNUSED const struct option_flags *flags)
{
int fd;
char *file;
gid_t gid;
mode_t mode;
const char *spool;
struct group *gr;
bool process_selinux;

process_selinux = !flags->chroot && !flags->prefix;
#ifdef WITH_SELINUX
bool process_selinux = !flags->chroot && !flags->prefix;
#endif

if (!strcaseeq(create_mail_spool, "yes"))
return;
Expand Down
Loading