new->bv_len = 0;
new->bv_val = NULL;
- assert( hash );
+ assert( hash != NULL );
lutil_passwd_hash( cred , hash, new, text );
}
if ( hash ) {
*hash = ber_strdup( cr );
rc = LUTIL_PASSWD_OK;
+
+ } else {
+ rc = strcmp( salt, cr ) ? LUTIL_PASSWD_ERR : LUTIL_PASSWD_OK;
}
- rc = strcmp( salt, cr ) ? LUTIL_PASSWD_ERR : LUTIL_PASSWD_OK;
}
ldap_pvt_thread_mutex_unlock( &passwd_mutex );