* src/passwd.c: (non PAM flavour) Report permission denied when
access to /etc/shadow fails with EACCES.
+2012-02-13 Mike Frysinger <vapier@gentoo.org>
+
+ * src/passwd.c: (non PAM flavour) Report permission denied when
+ access to /etc/shadow fails with EACCES.
+
2012-02-13 Mike Frysinger <vapier@gentoo.org>
* lib/nscd.c: Add missing newline to error message.
*/
sp = getspnam (name); /* !USE_PAM, no need for xgetspnam */
if (NULL == sp) {
+ if (errno == EACCES) {
+ (void) fprintf (stderr,
+ _("%s: Permission denied.\n"),
+ Prog);
+ exit (E_NOPERM);
+ }
sp = pwd_to_spwd (pw);
}