diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/inspircd.cpp | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/src/inspircd.cpp b/src/inspircd.cpp index 8cc1dd878..dea4b4575 100644 --- a/src/inspircd.cpp +++ b/src/inspircd.cpp @@ -136,15 +136,6 @@ namespace #endif } - // Deletes a pointer and then zeroes it. - template<typename T> - void DeleteZero(T*& pr) - { - T* p = pr; - pr = NULL; - delete p; - } - // Drops to the unprivileged user/group specified in <security:runas{user,group}>. void DropRoot() { @@ -423,9 +414,9 @@ void InspIRCd::Cleanup() delete FakeClient->server; FakeClient->cull(); } - DeleteZero(this->FakeClient); - DeleteZero(this->XLines); - DeleteZero(this->Config); + stdalgo::delete_zero(this->FakeClient); + stdalgo::delete_zero(this->XLines); + stdalgo::delete_zero(this->Config); SocketEngine::Deinit(); Logs->CloseLogs(); } |