diff --git a/ChangeLog b/ChangeLog index 112cbe43..eabbe517 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2009-04-22 Nicolas François + + * src/login.c: After login_prompt(), do not check for unset + username, but for empty username. + 2009-04-22 Nicolas François * lib/defines.h: Define USER_NAME_MAX_LENGTH, based on utmp and diff --git a/src/login.c b/src/login.c index 1fc69a07..cb08db0f 100644 --- a/src/login.c +++ b/src/login.c @@ -925,7 +925,7 @@ int main (int argc, char **argv) username[USER_NAME_MAX_LENGTH] = '\0'; login_prompt (_("\n%s login: "), username, USER_NAME_MAX_LENGTH); - if ('\0' == username) { + if ('\0' == username[0]) { /* Prompt for a new login */ free (username); username = NULL;