su: Allow disabled passwords
This commit is contained in:
parent
1005305d5a
commit
efeab5699e
@ -148,6 +148,12 @@ Result<int> luna_main(int argc, char** argv)
|
||||
{
|
||||
signal(SIGTTOU, SIG_IGN);
|
||||
|
||||
if (!strcmp(entry->pw_passwd, "!"))
|
||||
{
|
||||
fprintf(stderr, "%s: %s's password is disabled!\n", argv[0], entry->pw_name);
|
||||
return 1;
|
||||
}
|
||||
|
||||
char* pass = getpass();
|
||||
if (!pass) return 1;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user