This simplifies the code a little bit, and prepares for the next
commits, which will clean up further.
Signed-off-by: Alejandro Colomar <alx@kernel.org>
}
} else
#endif /* SHADOWGRP */
- {
+ if (!amroot) {
#ifdef FIRST_MEMBER_IS_ADMIN
/*
* The policy here for changing a group is that
* first group member might be just a normal user.
* --marekm
*/
- if (!amroot) {
- if (gr->gr_mem[0] == NULL) {
- failure ();
- }
+ if (gr->gr_mem[0] == NULL)
+ failure();
- if (strcmp (gr->gr_mem[0], myname) != 0) {
- failure ();
- }
- }
+ if (strcmp(gr->gr_mem[0], myname) != 0)
+ failure();
#else /* ! FIRST_MEMBER_IS_ADMIN */
- if (!amroot) {
- failure ();
- }
+ failure();
#endif
}
}