mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-21 17:54:48 +01:00
*Properly initialize members to prevent DB logging before the DB is started. Fixes a rarely seen startup crash.
*Code cleanup. --HG-- branch : trunk
This commit is contained in:
@@ -499,19 +499,9 @@ bool Master::_StartDB()
|
||||
sLog.outString("Realm running as realm ID %d", realmID);
|
||||
|
||||
///- Initialize the DB logging system
|
||||
if(sConfig.GetBoolDefault("EnableLogDB", false))
|
||||
{
|
||||
// everything successful - set var to enable DB logging once startup finished.
|
||||
sLog.SetLogDBLater(true);
|
||||
sLog.SetLogDB(false);
|
||||
sLog.SetRealmID(realmID);
|
||||
}
|
||||
else
|
||||
{
|
||||
sLog.SetLogDBLater(false);
|
||||
sLog.SetLogDB(false);
|
||||
sLog.SetRealmID(realmID);
|
||||
}
|
||||
sLog.SetLogDBLater(sConfig.GetBoolDefault("EnableLogDB", false)); // set var to enable DB logging once startup finished.
|
||||
sLog.SetLogDB(false);
|
||||
sLog.SetRealmID(realmID);
|
||||
|
||||
///- Clean the database before starting
|
||||
clearOnlineAccounts();
|
||||
|
||||
Reference in New Issue
Block a user