X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Ffilelogger.cpp;h=e567e4609b94c9132507e5a6cf59dd840c72bdaa;hb=8d3a30d4c5c1cc6ebeb62630b2aa05cd26c42303;hp=b0eb77310eca945fb875a2dd62bdbe2173d7ee27;hpb=4965a1d6697565b1a72de31deaccfd93180bd403;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/filelogger.cpp b/src/filelogger.cpp index b0eb77310..e567e4609 100644 --- a/src/filelogger.cpp +++ b/src/filelogger.cpp @@ -11,7 +11,7 @@ * --------------------------------------------------- */ -/* $Core: libIRCDfilelogger */ +/* $Core */ #include "inspircd.h" #include @@ -42,7 +42,9 @@ void FileLogStream::OnLog(int loglevel, const std::string &type, const std::stri /* If we were given -debug we output all messages, regardless of configured loglevel */ if ((loglevel < this->loglvl) && !ServerInstance->Config->forcedebug) + { return; + } if (ServerInstance->Time() != LAST) { @@ -54,14 +56,6 @@ void FileLogStream::OnLog(int loglevel, const std::string &type, const std::stri LAST = ServerInstance->Time(); } - if (ServerInstance->Config->log_file && ServerInstance->Config->writelog) - { - std::string out = std::string(TIMESTR) + " " + text.c_str() + "\n"; - this->f->WriteLogLine(out); - } - - if (ServerInstance->Config->nofork) - { - printf("%s %s\n", TIMESTR, text.c_str()); - } + std::string out = std::string(TIMESTR) + " " + text.c_str() + "\n"; + this->f->WriteLogLine(out); }