From 3cc56cf2e6575a79dc8c1894eef5b043f0cc9087 Mon Sep 17 00:00:00 2001 From: danieldg Date: Fri, 19 Mar 2010 18:06:39 +0000 Subject: Add RAWIO log level which is more verbose than DEBUG --- src/configreader.cpp | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'src/configreader.cpp') diff --git a/src/configreader.cpp b/src/configreader.cpp index 48d0477ea..b16b826c4 100644 --- a/src/configreader.cpp +++ b/src/configreader.cpp @@ -21,7 +21,7 @@ ServerConfig::ServerConfig() { WhoWasGroupSize = WhoWasMaxGroups = WhoWasMaxKeep = 0; - NoUserDns = OperSpyWhois = HideBans = HideSplits = UndernetMsgPrefix = NameOnlyModes = false; + RawLog = NoUserDns = OperSpyWhois = HideBans = HideSplits = UndernetMsgPrefix = NameOnlyModes = false; WildcardIPv6 = CycleHosts = InvBypassModes = true; dns_timeout = 5; MaxTargets = 20; @@ -788,9 +788,7 @@ void ConfigReaderThread::Finish() { ServerConfig* old = ServerInstance->Config; ServerInstance->Logs->Log("CONFIG",DEBUG,"Switching to new configuration..."); - ServerInstance->Logs->CloseLogs(); ServerInstance->Config = this->Config; - ServerInstance->Logs->OpenFileLogs(); Config->Apply(old, TheUserUID); if (Config->valid) @@ -811,13 +809,17 @@ void ConfigReaderThread::Finish() FOREACH_MOD(I_OnRehash, OnRehash(user)); ServerInstance->BuildISupport(); + ServerInstance->Logs->CloseLogs(); + ServerInstance->Logs->OpenFileLogs(); + + if (Config->RawLog) + ServerInstance->Users->ServerNoticeAll("*** Raw I/O logging is enabled on this server. All messages, passwords, and commands are being recorded."); + Config = old; } else { // whoops, abort! - ServerInstance->Logs->CloseLogs(); ServerInstance->Config = old; - ServerInstance->Logs->OpenFileLogs(); } } -- cgit v1.3.1-10-gc9f91