X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fbase.cpp;h=1f9ba3264d46bfb9be29403f8c14ba56257d9026;hb=f3d3ccaac1038775bf2cca62066e32cc2d52edc4;hp=ebd5214dbfee6d3738dfb6b31d15e68a3999f0fe;hpb=0827c5c7425a17b6a569a9f706b5b3dea8fa345a;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/base.cpp b/src/base.cpp index ebd5214db..1f9ba3264 100644 --- a/src/base.cpp +++ b/src/base.cpp @@ -1,10 +1,13 @@ /* * InspIRCd -- Internet Relay Chat Daemon * + * Copyright (C) 2013, 2018-2019 Sadie Powell + * Copyright (C) 2012, 2014-2015 Attila Molnar + * Copyright (C) 2012 Robby + * Copyright (C) 2010 Craig Edwards * Copyright (C) 2009 Daniel De Graaf * Copyright (C) 2007 Dennis Friis - * Copyright (C) 2004-2006 Craig Edwards - * Copyright (C) 2006 Oliver Lupton + * Copyright (C) 2006 Oliver Lupton * * 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 @@ -29,26 +32,27 @@ classbase::classbase() { +#ifdef INSPIRCD_ENABLE_RTTI if (ServerInstance) - ServerInstance->Logs->Log("CULLLIST", LOG_DEBUG, "classbase::+ @%p", (void*)this); + ServerInstance->Logs->Log("CULLLIST", LOG_DEBUG, "classbase::+%s @%p", typeid(*this).name(), (void*)this); +#endif } CullResult classbase::cull() { - if (ServerInstance) #ifdef INSPIRCD_ENABLE_RTTI - ServerInstance->Logs->Log("CULLLIST", LOG_DEBUG, "classbase::-%s @%p", - typeid(*this).name(), (void*)this); -#else - ServerInstance->Logs->Log("CULLLIST", LOG_DEBUG, "classbase::- @%p", (void*)this); + if (ServerInstance) + ServerInstance->Logs->Log("CULLLIST", LOG_DEBUG, "classbase::-%s @%p", typeid(*this).name(), (void*)this); #endif return CullResult(); } classbase::~classbase() { +#ifdef INSPIRCD_ENABLE_RTTI if (ServerInstance) - ServerInstance->Logs->Log("CULLLIST", LOG_DEBUG, "classbase::~ @%p", (void*)this); + ServerInstance->Logs->Log("CULLLIST", LOG_DEBUG, "classbase::~%s @%p", typeid(*this).name(), (void*)this); +#endif } CullResult::CullResult() @@ -295,7 +299,7 @@ LocalStringExt::~LocalStringExt() std::string LocalStringExt::ToInternal(const Extensible* container, void* item) const { - return item ? *static_cast(item) : std::string(); + return item ? *static_cast(item) : std::string(); } void LocalStringExt::FromInternal(Extensible* container, const std::string& value)