aboutsummaryrefslogtreecommitdiff
path: root/loginutils/login.c
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2013-11-19 13:09:06 +0100
committerDenys Vlasenko <vda.linux@googlemail.com>2013-11-19 13:09:06 +0100
commit9c1c605b1a8f34aef347bd9c2e4aea251e556d1b (patch)
tree1854674f7025a8679bd42bd4f056d22a6df891a3 /loginutils/login.c
parentf6beef63c64abfc126ea4e73147af29d152f1a9e (diff)
downloadbusybox-9c1c605b1a8f34aef347bd9c2e4aea251e556d1b.tar.gz
sulogin: use common password-checking routine.
This needed some extensions correct_passwd() function, which got renamed ask_and_check_password() to better describe what it does. function old new delta ask_and_check_password_extended - 215 +215 ask_and_check_password - 12 +12 vlock_main 394 397 +3 sulogin_main 494 326 -168 correct_password 207 - -207 ------------------------------------------------------------------------------ (add/remove: 2/1 grow/shrink: 1/1 up/down: 230/-375) Total: -145 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'loginutils/login.c')
-rw-r--r--loginutils/login.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/loginutils/login.c b/loginutils/login.c
index 6ec8dc42e..a4b19ccfc 100644
--- a/loginutils/login.c
+++ b/loginutils/login.c
@@ -420,7 +420,7 @@ int login_main(int argc UNUSED_PARAM, char **argv)
* Note that reads (in no-echo mode) trash tty attributes.
* If we get interrupted by SIGALRM, we need to restore attrs.
*/
- if (correct_password(pw))
+ if (ask_and_check_password(pw) > 0)
break;
#endif /* ENABLE_PAM */
auth_failed: