+2009-04-22 Nicolas François <nicolas.francois@centraliens.net>
+
+ * src/login.c: Added assert()s for NULL (or ! NULL) username, and
+ pwd. This helps splint.
+
2009-04-22 Nicolas François <nicolas.francois@centraliens.net>
* src/login.c: After login_prompt(), do not check for unset
* Get the user name.
*/
if (optind < argc) {
+ assert (NULL == username);
username = xstrdup (argv[optind]);
strzero (argv[optind]);
++optind;
}
#ifdef RLOGIN
if (rflg) {
+ assert (NULL == username);
username = xmalloc (USER_NAME_MAX_LENGTH + 1);
username[USER_NAME_MAX_LENGTH] = '\0';
if (do_rlogin (hostname, username, USER_NAME_MAX_LENGTH, term, sizeof term)) {
}
} /* while (true) */
#endif /* ! USE_PAM */
+ assert (NULL != username);
+ assert (NULL != pwd);
(void) alarm (0); /* turn off alarm clock */