X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Flogger.cpp;h=5ebcf4b00d782f0b5903a38c1d092ca94413c017;hb=d494fa6e094e85cd29235e995fb2b447d6e1f168;hp=22896bd4f31204b99f096f43d83004605fc8c685;hpb=35b70631f0532a5828b04a8e0c02092a285f331a;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/logger.cpp b/src/logger.cpp index 22896bd4f..5ebcf4b00 100644 --- a/src/logger.cpp +++ b/src/logger.cpp @@ -1,10 +1,16 @@ /* * InspIRCd -- Internet Relay Chat Daemon * - * Copyright (C) 2009 Daniel De Graaf - * Copyright (C) 2008 Craig Edwards + * Copyright (C) 2013-2014 Attila Molnar + * Copyright (C) 2013, 2017-2018, 2020 Sadie Powell + * Copyright (C) 2013 Daniel Vassdal + * Copyright (C) 2012 Robby + * Copyright (C) 2010 Craig Edwards + * Copyright (C) 2010 Adam + * Copyright (C) 2009-2010 Daniel De Graaf + * Copyright (C) 2009 Uli Schlachter + * Copyright (C) 2008-2009 Robin Burchell * Copyright (C) 2008 Thomas Stagner - * Copyright (C) 2008 Robin Burchell * * This file is part of InspIRCd. InspIRCd is free software: you can * redistribute it and/or modify it under the terms of the GNU General Public @@ -50,7 +56,7 @@ */ const char LogStream::LogHeader[] = - "Log started for " INSPIRCD_VERSION " (" MODULE_INIT_STR ")"; + "Log started for " INSPIRCD_VERSION; LogManager::LogManager() : Logging(false) @@ -77,35 +83,35 @@ void LogManager::OpenFileLogs() { ConfigTag* tag = i->second; std::string method = tag->getString("method"); - if (method != "file") + if (!stdalgo::string::equalsci(method, "file")) { continue; } std::string type = tag->getString("type"); std::string level = tag->getString("level"); LogLevel loglevel = LOG_DEFAULT; - if (level == "rawio") + if (stdalgo::string::equalsci(level, "rawio")) { loglevel = LOG_RAWIO; ServerInstance->Config->RawLog = true; } - else if (level == "debug") + else if (stdalgo::string::equalsci(level, "debug")) { loglevel = LOG_DEBUG; } - else if (level == "verbose") + else if (stdalgo::string::equalsci(level, "verbose")) { loglevel = LOG_VERBOSE; } - else if (level == "default") + else if (stdalgo::string::equalsci(level, "default")) { loglevel = LOG_DEFAULT; } - else if (level == "sparse") + else if (stdalgo::string::equalsci(level, "sparse")) { loglevel = LOG_SPARSE; } - else if (level == "none") + else if (stdalgo::string::equalsci(level, "none")) { loglevel = LOG_NONE; }