From a87326fb1759a9b96de8b0a0842bba1d4177e04e Mon Sep 17 00:00:00 2001 From: w00t Date: Sun, 28 Oct 2007 19:32:23 +0000 Subject: Make ZLine use Matches() git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8406 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/xline.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/xline.cpp b/src/xline.cpp index 537b86596..857c54069 100644 --- a/src/xline.cpp +++ b/src/xline.cpp @@ -466,13 +466,13 @@ void XLineManager::zline_set_creation_time(const char* ip, time_t create_time) // returns a pointer to the reason if an ip address matches a zline, NULL if it didnt match -ZLine* XLineManager::matches_zline(const char* ipaddr) +ZLine* XLineManager::matches_zline(User *u) { if (zlines.empty()) return NULL; for (std::vector::iterator i = zlines.begin(); i != zlines.end(); i++) - if (match(ipaddr,(*i)->ipaddr, true)) + if ((*i)->Matches(u)) return (*i); return NULL; } @@ -609,7 +609,7 @@ void XLineManager::ApplyLines() } if ((What & APPLY_ZLINES) && (zlines.size())) { - if ((check = matches_zline(u->GetIPString()))) + if ((check = matches_zline(u))) { snprintf(reason,MAXBUF,"Z-Lined: %s", check->reason); if (*ServerInstance->Config->MoronBanner) @@ -689,7 +689,7 @@ bool ELine::Matches(User *u) bool ZLine::Matches(User *u) { - if (match(user->GetIPString(), this->ipaddr, true)) + if (match(u->GetIPString(), this->ipaddr, true)) return true; else return false; -- cgit v1.2.3