From 7a320a00dfd5f69dedda1e8697ced03cebb71717 Mon Sep 17 00:00:00 2001 From: w00t Date: Fri, 11 Jan 2008 21:57:52 +0000 Subject: Backport : Explicitly allow channels denied by git-svn-id: http://svn.inspircd.org/repository/branches/1_1_stable@8698 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/modules/m_denychans.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src') diff --git a/src/modules/m_denychans.cpp b/src/modules/m_denychans.cpp index 738a58103..371c58cac 100644 --- a/src/modules/m_denychans.cpp +++ b/src/modules/m_denychans.cpp @@ -68,11 +68,21 @@ class ModuleDenyChannels : public Module else { std::string reason = Conf->ReadValue("badchan","reason",j); + + for (int j = 0; j < Conf->Enumerate("goodchan"); j++) + { + if (match(cname, Conf->ReadValue("goodchan", "name", j).c_str())) + { + return 0; + } + } + user->WriteServ("926 %s %s :Channel %s is forbidden: %s",user->nick,cname,cname,reason.c_str()); return 1; } } } + return 0; } }; -- cgit v1.3.1-10-gc9f91