From 369ee31c56efa23e8a9f82378d1b136fbe59aea2 Mon Sep 17 00:00:00 2001 From: peavey Date: Wed, 24 Jan 2007 01:31:19 +0000 Subject: Fix endless loop on dns hit. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6433 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/modules/m_dnsbl.cpp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/src/modules/m_dnsbl.cpp b/src/modules/m_dnsbl.cpp index 4391272e1..213c2f67e 100644 --- a/src/modules/m_dnsbl.cpp +++ b/src/modules/m_dnsbl.cpp @@ -96,7 +96,7 @@ class DNSBLResolver : public Resolver while (x != std::string::npos) { reason.erase(x, 4); - reason.insert(x, "%ip%"); + reason.insert(x, them->GetIPString()); x = reason.find("%ip%"); } @@ -138,7 +138,7 @@ class DNSBLResolver : public Resolver virtual void OnError(ResolverError e, const std::string &errormessage) { } - + virtual ~DNSBLResolver() { } @@ -148,7 +148,7 @@ class ModuleDNSBL : public Module { private: std::vector DNSBLConfEntries; - + /* * Convert a string to EnumBanaction */ @@ -162,7 +162,7 @@ class ModuleDNSBL : public Module return DNSBLConfEntry::I_ZLINE; if(action.compare("GLINE")==0) return DNSBLConfEntry::I_GLINE; - + return DNSBLConfEntry::I_UNKNOWN; } public: @@ -170,12 +170,12 @@ class ModuleDNSBL : public Module { ReadConf(); } - + virtual ~ModuleDNSBL() { ClearEntries(); } - + virtual Version GetVersion() { return Version(2, 0, 0, 1, VF_VENDOR, API_VERSION); @@ -199,7 +199,7 @@ class ModuleDNSBL : public Module } /** Fill our conf vector with data - */ + */ virtual void ReadConf() { ConfigReader *MyConf = new ConfigReader(ServerInstance); @@ -311,16 +311,16 @@ class ModuleDNSBLFactory : public ModuleFactory ModuleDNSBLFactory() { } - + ~ModuleDNSBLFactory() { } - + virtual Module *CreateModule(InspIRCd *Me) { return new ModuleDNSBL(Me); } - + }; -- cgit v1.2.3