From 61e121fb7debd46ea391ab2cfca0df036cef5f07 Mon Sep 17 00:00:00 2001 From: brain Date: Sat, 24 Apr 2004 21:21:29 +0000 Subject: Added G-line, Z-line and K-line plus SZLINE, SGLINE, etc. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@716 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/xline.cpp | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) (limited to 'src/xline.cpp') diff --git a/src/xline.cpp b/src/xline.cpp index 400fac241..1ef612ff1 100644 --- a/src/xline.cpp +++ b/src/xline.cpp @@ -345,6 +345,45 @@ char* matches_gline(const char* host) return NULL; } +void gline_set_creation_time(char* host, time_t create_time) +{ + for (std::vector::iterator i = glines.begin(); i != glines.end(); i++) + { + if (!strcasecmp(host,i->hostmask)) + { + i->set_time = create_time; + return; + } + } + return ; +} + +void qline_set_creation_time(char* nick, time_t create_time) +{ + for (std::vector::iterator i = qlines.begin(); i != qlines.end(); i++) + { + if (!strcasecmp(nick,i->nick)) + { + i->set_time = create_time; + return; + } + } + return ; +} + +void zline_set_creation_time(char* ip, time_t create_time) +{ + for (std::vector::iterator i = zlines.begin(); i != zlines.end(); i++) + { + if (!strcasecmp(ip,i->ipaddr)) + { + i->set_time = create_time; + return; + } + } + return ; +} + // returns a pointer to the reason if an ip address matches a zline, NULL if it didnt match char* matches_zline(const char* ipaddr) -- cgit v1.3.1-10-gc9f91