IRC operators w/OperCanMode can kick anyone
authorLucentW <LucentW@users.noreply.github.com>
Mon, 11 May 2015 20:05:08 +0000 (22:05 +0200)
committerLucentW <LucentW@users.noreply.github.com>
Mon, 11 May 2015 20:12:30 +0000 (22:12 +0200)
src/ngircd/channel.c

index 6d8dde3e1e2004d96b580e51ca210f4eb3bfe2fa..e74cd6eb1dfcc4358668a1c5ec18ec040471d697 100644 (file)
@@ -359,6 +359,11 @@ Channel_Kick(CLIENT *Peer, CLIENT *Target, CLIENT *Origin, const char *Name,
                    !Channel_UserHasMode(chan, Target, 'a') &&
                    !Channel_UserHasMode(chan, Target, 'o'))
                        can_kick = true;
                    !Channel_UserHasMode(chan, Target, 'a') &&
                    !Channel_UserHasMode(chan, Target, 'o'))
                        can_kick = true;
+               
+               /* IRC operators & IRCd with OperCanMode enabled
+                * can kick anyways regardless of privilege */  
+               else if(Client_HasMode(Origin, 'o') && Conf_OperCanMode)
+                   can_kick = true;
 
                if(!can_kick) {
                        IRC_WriteErrClient(Origin, ERR_CHANOPPRIVTOOLOW_MSG,
 
                if(!can_kick) {
                        IRC_WriteErrClient(Origin, ERR_CHANOPPRIVTOOLOW_MSG,