summaryrefslogtreecommitdiff
path: root/include/logger.h
diff options
context:
space:
mode:
authoraquanight <aquanight@e03df62e-2008-0410-955e-edbf42e46eb7>2008-02-14 00:43:48 +0000
committeraquanight <aquanight@e03df62e-2008-0410-955e-edbf42e46eb7>2008-02-14 00:43:48 +0000
commitf995b32ff4a570f3c35521e5d426286dd25c1c89 (patch)
treefac73998662b97f9c594da716fe32c8e3111ae79 /include/logger.h
parent0fed3a06d0f889dc9429f74fcfff9398d2f29add (diff)
More <log> stuff
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8928 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'include/logger.h')
-rw-r--r--include/logger.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/include/logger.h b/include/logger.h
index c4729035c..c9e9f8c0e 100644
--- a/include/logger.h
+++ b/include/logger.h
@@ -86,7 +86,7 @@ class CoreExport LogStream : public classbase
virtual ~LogStream() { }
- virtual void OnLog(int loglevel, const std::string &type, const std::string &msg) { }
+ virtual void OnLog(int loglevel, const std::string &type, const std::string &msg) = 0;
};
typedef std::map<FileWriter*, int> FileLogMap;
@@ -97,6 +97,7 @@ class CoreExport LogManager : public classbase
bool Logging; // true when logging, avoids recursion
InspIRCd *ServerInstance;
std::map<std::string, std::vector<LogStream *> > LogStreams;
+ std::map<LogStream *, int> AllLogStreams; // holds all logstreams
std::vector<LogStream *> GlobalLogStreams; //holds all logstreams with a type of *
FileLogMap FileLogs; /* Holds all file logs, refcounted */
public:
@@ -134,6 +135,7 @@ class CoreExport LogManager : public classbase
void OpenFileLogs();
void CloseLogs();
bool AddLogType(const std::string &type, LogStream *l);
+ void DelLogStream(LogStream* l);
bool DelLogType(const std::string &type, LogStream *l);
void Log(const std::string &type, int loglevel, const std::string &msg);
void Log(const std::string &type, int loglevel, const char *fmt, ...);