diff options
| author | 2023-01-09 18:30:09 +0000 | |
|---|---|---|
| committer | 2023-01-09 18:33:37 +0000 | |
| commit | 610930faced65f418d21f03058519456f713505d (patch) | |
| tree | 9b50b58d2dd2e7ccca3c62f5557d75cd2cd0c3ec /src/logging.cpp | |
| parent | Fix enabling the raw I/O logging warning when <log:level> is rawio. (diff) | |
Deduplicate sending the raw I/O logging warning.
Diffstat (limited to 'src/logging.cpp')
| -rw-r--r-- | src/logging.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/logging.cpp b/src/logging.cpp index 249dd86e1..60c5d420a 100644 --- a/src/logging.cpp +++ b/src/logging.cpp @@ -18,6 +18,7 @@ #include "inspircd.h" +#include "clientprotocolmsg.h" const char* Log::LevelToString(Log::Level level) { @@ -178,6 +179,12 @@ void Log::Manager::EnableDebugMode() ServerInstance->Config->RawLog = true; } +void Log::Manager::NotifyRawIO(LocalUser* user, MessageType type) +{ + ClientProtocol::Messages::Privmsg msg(ServerInstance->FakeClient, user, "*** Raw I/O logging is enabled on this server. All messages, passwords, and commands are being recorded.", type); + user->Send(ServerInstance->GetRFCEvents().privmsg, msg); +} + void Log::Manager::OpenLogs(bool requiremethods) { // If the server is started in debug mode we don't write logs. |
