diff --git a/common/eqemu_logsys.cpp b/common/eqemu_logsys.cpp index 9f5a94d7a..6354d7a19 100644 --- a/common/eqemu_logsys.cpp +++ b/common/eqemu_logsys.cpp @@ -82,8 +82,9 @@ EQEmuLogSys::~EQEmuLogSys(){ void EQEmuLogSys::LoadLogSettingsDefaults() { + /* Get Executable platform currently running this code (Zone/World/etc) */ log_platform = GetExecutablePlatformInt(); - /* Write defaults */ + /* Zero out Array */ for (int i = 0; i < Logs::LogCategory::MaxCategoryID; i++){ log_settings[i].log_to_console = 0; log_settings[i].log_to_file = 0; @@ -96,8 +97,6 @@ void EQEmuLogSys::LoadLogSettingsDefaults() log_settings[Logs::UCS_Server].log_to_console = 1; log_settings[Logs::Crash].log_to_console = 1; log_settings[Logs::MySQLError].log_to_console = 1; - - log_settings_loaded = true; } std::string EQEmuLogSys::FormatOutMessageString(uint16 log_category, std::string in_message){ diff --git a/common/eqemu_logsys.h b/common/eqemu_logsys.h index 66124df74..26cffdc57 100644 --- a/common/eqemu_logsys.h +++ b/common/eqemu_logsys.h @@ -141,10 +141,11 @@ public: LogSettings log_settings[Logs::LogCategory::MaxCategoryID]; - bool log_settings_loaded = false; - bool file_logs_enabled = false; + bool file_logs_enabled = false; /* Set when log settings are loaded to determine if keeping a file open is necessary */ - int log_platform = 0; + int log_platform = 0; /* Sets Executable platform (Zone/World/UCS) etc. */ + + std::string process_file_name; /* File name used in writing logs */ uint16 GetGMSayColorFromCategory(uint16 log_category); diff --git a/queryserv/queryserv.cpp b/queryserv/queryserv.cpp index f285f8410..1f9aa5b1d 100644 --- a/queryserv/queryserv.cpp +++ b/queryserv/queryserv.cpp @@ -77,15 +77,15 @@ int main() { Log.Out(Logs::General, Logs::QS_Server, "Connecting to MySQL..."); /* MySQL Connection */ - if (!database.Connect( - Config->QSDatabaseHost.c_str(), - Config->QSDatabaseUsername.c_str(), - Config->QSDatabasePassword.c_str(), - Config->QSDatabaseDB.c_str(), - Config->QSDatabasePort)) { - Log.Out(Logs::General, Logs::QS_Server, "Cannot continue without a database connection."); - return 1; - } + // if (!database.Connect( + // Config->QSDatabaseHost.c_str(), + // Config->QSDatabaseUsername.c_str(), + // Config->QSDatabasePassword.c_str(), + // Config->QSDatabaseDB.c_str(), + // Config->QSDatabasePort)) { + // Log.Out(Logs::General, Logs::QS_Server, "Cannot continue without a database connection."); + // return 1; + // } /* Register Log System and Settings */ database.LoadLogSysSettings(Log.log_settings);