From: brain Date: Wed, 2 Apr 2008 19:17:34 +0000 (+0000) Subject: Depreciated ServerInstance->Log() seems to crash configreader on rehash? We should... X-Git-Tag: v2.0.23~3557 X-Git-Url: https://git.netwichtig.de/gitweb/?a=commitdiff_plain;h=0ba0beb0c465cd7bfbd98b6f51429d3147c362eb;p=user%2Fhenk%2Fcode%2Finspircd.git Depreciated ServerInstance->Log() seems to crash configreader on rehash? We should remove the depreciated calls anyway, so im not too concerned as to why they crash - probably not threadsafe. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9275 e03df62e-2008-0410-955e-edbf42e46eb7 --- diff --git a/src/configreader.cpp b/src/configreader.cpp index 2c5d01ee1..df7721e82 100644 --- a/src/configreader.cpp +++ b/src/configreader.cpp @@ -1145,12 +1145,12 @@ void ServerConfig::Read(bool bail, User* user) // write once here, to try it out and make sure its ok ServerInstance->WritePID(this->PID); - ServerInstance->Log(DEFAULT,"Done reading configuration file."); - /* Switch over logfiles */ ServerInstance->Logs->CloseLogs(); ServerInstance->Logs->OpenFileLogs(); + ServerInstance->Logs->Log("CONFIG", DEFAULT, "Done reading configuration file."); + /* If we're rehashing, let's load any new modules, and unload old ones */ if (!bail) @@ -1215,7 +1215,7 @@ void ServerConfig::Read(bool bail, User* user) } } - ServerInstance->Log(DEFAULT,"Successfully unloaded %lu of %lu modules and loaded %lu of %lu modules.",(unsigned long)rem,(unsigned long)removed_modules.size(),(unsigned long)add,(unsigned long)added_modules.size()); + ServerInstance->Logs->Log("CONFIG", DEFAULT, "Successfully unloaded %lu of %lu modules and loaded %lu of %lu modules.",(unsigned long)rem,(unsigned long)removed_modules.size(),(unsigned long)add,(unsigned long)added_modules.size()); ServerInstance->Threads->Mutex(false);