diff options
author | danieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7> | 2009-10-18 01:40:26 +0000 |
---|---|---|
committer | danieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7> | 2009-10-18 01:40:26 +0000 |
commit | 93a78a57ada6d5dab410c2bd3c4b02f4fa15684c (patch) | |
tree | 82e2ef7308da4fdc8a24bd91a681fd66898937fe /src/base.cpp | |
parent | cced60255b08181d35b9bb26545a85feebd6b5cb (diff) |
Add more debug logging of object lifetimes
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11900 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/base.cpp')
-rw-r--r-- | src/base.cpp | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/base.cpp b/src/base.cpp index 2e2dbfb28..15a642eb4 100644 --- a/src/base.cpp +++ b/src/base.cpp @@ -11,24 +11,32 @@ * --------------------------------------------------- */ -/* $Core */ - #include "inspircd_config.h" #include "base.h" #include <time.h> #include "inspircd.h" +#include <typeinfo> classbase::classbase() { + if (ServerInstance && ServerInstance->Logs) + ServerInstance->Logs->Log("CULLLIST", DEBUG, "classbase::+%s @%p", + typeid(*this).name(), (void*)this); } CullResult classbase::cull() { + if (ServerInstance && ServerInstance->Logs) + ServerInstance->Logs->Log("CULLLIST", DEBUG, "classbase::-%s @%p", + typeid(*this).name(), (void*)this); return CullResult(); } classbase::~classbase() { + if (ServerInstance && ServerInstance->Logs) + ServerInstance->Logs->Log("CULLLIST", DEBUG, "classbase::~%s @%p", + typeid(*this).name(), (void*)this); } CullResult::CullResult() |