repo: ngircd
action: commit
revision: 
path_from: 
revision_from: 83bfdddf995bd0a3b23ce7e7da3719e4b73c782e:
path_to: 
revision_to: 
git.thebackupbox.net
ngircd
git clone git://git.thebackupbox.net/ngircd
commit 83bfdddf995bd0a3b23ce7e7da3719e4b73c782e
Author: Rolf Eike Beer 
Date:   Sun May 4 15:27:34 2008 +0200

    Allow IRC ops to ignore channel limits when joining

    Allow IRC ops to ignore any channel limit (bans, invite only etc.) when they
    want to join a channel.

diff --git a/src/ngircd/irc-channel.c b/src/ngircd/irc-channel.c
index 934c9082c8f4647bf41f0ceb1751c7ac93d50a31..
index ..e95999275aaab341c5a40252754d7343efa99df7 100644
--- a/src/ngircd/irc-channel.c
+++ b/src/ngircd/irc-channel.c
@@ -70,6 +70,10 @@ join_allowed(CLIENT *Client, CLIENT *target, CHANNEL *chan,
 	bool is_invited, is_banned;
 	const char *channel_modes;

+	/* Allow IRC operators to overwrite channel limits */
+	if (strchr(Client_Modes(Client), 'o'))
+		return true;
+
 	is_banned = Lists_Check(Channel_GetListBans(chan), target);
 	is_invited = Lists_Check(Channel_GetListInvites(chan), target);

-----END OF PAGE-----