Issue information

Issue ID
#4361
Status
Fixed
Severity
Low
Started
Hercules Elf Bot
Jul 21, 2010 15:17
Last Post
Hercules Elf Bot
Jul 21, 2010 15:17
Confirmation
N/A

Hercules Elf Bot - Jul 21, 2010 15:17

Originally posted by [b]Ai4rei[/b]
http://www.eathena.ws/board/index.php?autocom=bugtracker&showbug=4361

CODE
    // Account database init
    accounts = get_account_engine();
    if( accounts == NULL )
    {
        ShowError("do_init: account engine '%s' not found.\n", login_config.account_engine);
        runflag = 0;
        return 1;
    }
    else
    {
        ShowInfo("Using account engine '%s'.\n", login_config.account_engine);
        accounts->init(accounts);
    }

The return value of accounts->init(account); is not checked, whether it is true, or not. Which means, even if the initialization of the account engine fails (sql server down, txt data not accessible), the login server does not abort. On TXT this additionally leads to delete_timer of timer -1 (db->save_timer), because the timer not initialized, if TXT database reading fails.

This problem exists since r13000, where the new login server was merged into trunk (down to r12700 in the /loginmerge branch).

This post has been edited by Ai4rei: Nov 20 2010, 05:06 AM