Android returns NULL for pw_crypt, set it to something else

This commit is contained in:
Matt Johnston 2013-03-19 20:15:44 +08:00
parent da59afe798
commit 5ff341206e

View File

@ -462,6 +462,10 @@ void fill_passwd(const char* username) {
passwd_crypt = spasswd->sp_pwdp;
}
#endif
if (!passwd_crypt) {
/* android supposedly returns NULL */
passwd_crypt = "!!";
}
ses.authstate.pw_passwd = m_strdup(passwd_crypt);
}
}