X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fmodules%2Fm_hostchange.cpp;h=de485b2c03e9c456917ab460ee3f3c4ea952d80c;hb=2330fc9ddd48c939e894e7e37e9bb2e62eafc38d;hp=f6fd2bfa362c64f76b16c3a8f06887d73d11d438;hpb=71a86d7d6b57fe5ca2a8b1478892ddb9832e6375;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/modules/m_hostchange.cpp b/src/modules/m_hostchange.cpp index f6fd2bfa3..de485b2c0 100644 --- a/src/modules/m_hostchange.cpp +++ b/src/modules/m_hostchange.cpp @@ -20,10 +20,11 @@ using namespace std; #include "users.h" #include "channels.h" #include "modules.h" +#include "inspircd.h" /* $ModDesc: Provides masking of user hostnames in a different way to m_cloaking */ -class Host +class Host : public classbase { public: std::string action; @@ -46,13 +47,13 @@ class ModuleHostChange : public Module : Module::Module(Me) { Srv = Me; - Conf = new ConfigReader; + Conf = new ConfigReader; OnRehash(""); } virtual ~ModuleHostChange() { - delete Conf; + DELETE(Conf); } Priority Prioritize() @@ -65,14 +66,14 @@ class ModuleHostChange : public Module List[I_OnRehash] = List[I_OnUserConnect] = 1; } - virtual void OnRehash(std::string parameter) + virtual void OnRehash(const std::string ¶meter) { - delete Conf; + DELETE(Conf); Conf = new ConfigReader; MySuffix = Conf->ReadValue("host","suffix",0); for (hostchanges_t::iterator i = hostchanges.begin(); i != hostchanges.end(); i++) { - delete i->second; + DELETE(i->second); } hostchanges.clear(); for (int index = 0; index < Conf->Enumerate("hostchange"); index++)