Properly handle net rider kicks that are received after a normal kick for the same...
[ircu2.10.12-pk.git] / ircd / m_wallchops.c
index b569c83892631e26ff1251d0fa2f03d36e82af71..a3a91339eaddc343b5044c04a09c3ac23fb71d6e 100644 (file)
@@ -85,6 +85,7 @@
 #include "client.h"
 #include "hash.h"
 #include "ircd.h"
+#include "ircd_log.h"
 #include "ircd_reply.h"
 #include "ircd_string.h"
 #include "msg.h"
@@ -93,7 +94,7 @@
 #include "s_user.h"
 #include "send.h"
 
-#include <assert.h>
+/* #include <assert.h> -- Now using assert in ircd_log.h */
 
 /*
  * m_wallchops - local generic message handler
@@ -143,7 +144,7 @@ int ms_wallchops(struct Client* cptr, struct Client* sptr, int parc, char* parv[
   if (parc < 3 || !IsUser(sptr))
     return 0;
 
-  if ((chptr = FindChannel(parv[1]))) {
+  if (!IsLocalChannel(parv[1]) && (chptr = FindChannel(parv[1]))) {
     if (client_can_send_to_channel(sptr, chptr, 0)) {
       sendcmdto_channel_butone(sptr, CMD_WALLCHOPS, chptr, cptr,
                               SKIP_DEAF | SKIP_BURST | SKIP_NONOPS,