summaryrefslogtreecommitdiff
path: root/auth-passwd.c
diff options
context:
space:
mode:
Diffstat (limited to 'auth-passwd.c')
-rw-r--r--auth-passwd.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/auth-passwd.c b/auth-passwd.c
index b1c6ce092..68bbd18dd 100644
--- a/auth-passwd.c
+++ b/auth-passwd.c
@@ -209,6 +209,7 @@ sys_auth_passwd(Authctxt *authctxt, const char *password)
209 * Authentication is accepted if the encrypted passwords 209 * Authentication is accepted if the encrypted passwords
210 * are identical. 210 * are identical.
211 */ 211 */
212 return (strcmp(encrypted_password, pw_password) == 0); 212 return encrypted_password != NULL &&
213 strcmp(encrypted_password, pw_password) == 0;
213} 214}
214#endif 215#endif