* | Inspire Internet Relay Chat Daemon |
* +------------------------------------+
*
- * InspIRCd: (C) 2002-2009 InspIRCd Development Team
+ * InspIRCd: (C) 2002-2010 InspIRCd Development Team
* See: http://wiki.inspircd.org/Credits
*
* This program is free but copyrighted software; see
if (this->BanHash->find(ip) != this->BanHash->end()) // can't have two cache entries on the same IP, sorry..
return NULL;
- b = new BanCacheHit(ServerInstance, ip, type, reason);
+ b = new BanCacheHit(ip, type, reason);
this->BanHash->insert(std::make_pair(ip, b));
return b;
if (this->BanHash->find(ip) != this->BanHash->end()) // can't have two cache entries on the same IP, sorry..
return NULL;
- b = new BanCacheHit(ServerInstance, ip, type, reason, seconds);
+ b = new BanCacheHit(ip, type, reason, seconds);
this->BanHash->insert(std::make_pair(ip, b));
return b;
delete BanHash;
BanHash = NewHash;
}
+
+BanCacheManager::~BanCacheManager()
+{
+ for (BanCacheHash::iterator n = BanHash->begin(); n != BanHash->end(); ++n)
+ delete n->second;
+ delete BanHash;
+}