ubase

suckless linux base utils
git clone git://git.2f30.org/ubase.git
Log | Files | Refs | README | LICENSE

commit 4c38dffadee9bd29fa85dffef3ea4b63d6704183
parent 4b05ca07cc622f0b50092cda3318cd804730eafc
Author: sin <sin@2f30.org>
Date:   Mon Jun  9 12:06:45 +0100

If the user password is empty check it against the provided pass as well

Diffstat:
util/passwd.c | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/util/passwd.c b/util/passwd.c @@ -24,7 +24,7 @@ pw_check(struct passwd *pw, const char *pass) } if (pw->pw_passwd[0] == '\0') - return 1; + return pass[0] == '\0' ? 1 : 0; if (pw->pw_passwd[0] == 'x' && pw->pw_passwd[1] == '\0') { errno = 0;