Committer  : entrope
CVSROOT    : /cvsroot/undernet-ircu
Module     : ircu2.10
Commit time: 2005-04-22 23:36:41 UTC

Modified files:
     ChangeLog RELEASE.NOTES ircd/channel.c ircd/m_silence.c

Log message:

Fix silence bugs found by coekie and ban application bug found by xplora.

---------------------- diff included ----------------------
Index: ircu2.10/ChangeLog
diff -u ircu2.10/ChangeLog:1.607 ircu2.10/ChangeLog:1.608
--- ircu2.10/ChangeLog:1.607    Thu Apr 21 18:39:06 2005
+++ ircu2.10/ChangeLog  Fri Apr 22 16:36:29 2005
@@ -1,3 +1,12 @@
+2005-04-22  Michael Poole <[EMAIL PROTECTED]>
+
+       * RELEASE.NOTES: Silence exceptions use ~, not -.  Oops!
+
+       * ircd/channel.c (mode_parse_ban): Use correct test for flag_p.
+
+       * ircd/m_silence.c (apply_silence): Make mask pretty so that later
+       processing does not convert * to @ (and match no one).
+
 2005-04-21  Kevin L. Mitchell  <[EMAIL PROTECTED]>
 
        * ircd/m_userip.c (userip_formatter): /userip should *never*
Index: ircu2.10/RELEASE.NOTES
diff -u ircu2.10/RELEASE.NOTES:1.15 ircu2.10/RELEASE.NOTES:1.16
--- ircu2.10/RELEASE.NOTES:1.15 Sat Jan 15 07:23:02 2005
+++ ircu2.10/RELEASE.NOTES      Fri Apr 22 16:36:30 2005
@@ -63,8 +63,8 @@
 Client blocks (previously I: lines), Operator blocks (previously O:
 and o: lines), channel bans and silences may use CIDR notation instead
 of simple wildcards.  You may also have silence exceptions by putting
-'-' before the mask; for example, if you wish to silence everyone
-except X, you could use SILENCE [EMAIL PROTECTED],[EMAIL PROTECTED]
+'~' before the mask; for example, if you wish to silence everyone
+except X, you could use SILENCE [EMAIL PROTECTED],[EMAIL PROTECTED]
 
 The server will no longer kick "net riders" in keyed (+k) channels if
 both sides of the net join have the same key.
Index: ircu2.10/ircd/channel.c
diff -u ircu2.10/ircd/channel.c:1.125 ircu2.10/ircd/channel.c:1.126
--- ircu2.10/ircd/channel.c:1.125       Sun Apr 17 09:59:48 2005
+++ ircu2.10/ircd/channel.c     Fri Apr 22 16:36:30 2005
@@ -19,7 +19,7 @@
  */
 /** @file
  * @brief Channel management and maintenance
- * @version $Id: channel.c,v 1.125 2005/04/17 16:59:48 entrope Exp $
+ * @version $Id: channel.c,v 1.126 2005/04/22 23:36:30 entrope Exp $
  */
 #include "config.h"
 
@@ -2787,7 +2787,7 @@
   newban = state->banlist + (state->numbans++);
   newban->next = 0;
   newban->flags = ((state->dir == MODE_ADD) ? BAN_ADD : BAN_DEL)
-      | (*flag_p == 'b' ? 0 : BAN_EXCEPTION);
+      | (*flag_p == MODE_BAN ? 0 : BAN_EXCEPTION);
   newban->banstr = NULL;
   set_ban_mask(newban, collapse(pretty_mask(t_str)));
   newban->who = cli_name(state->sptr);
Index: ircu2.10/ircd/m_silence.c
diff -u ircu2.10/ircd/m_silence.c:1.10 ircu2.10/ircd/m_silence.c:1.11
--- ircu2.10/ircd/m_silence.c:1.10      Fri Feb 18 19:09:29 2005
+++ ircu2.10/ircd/m_silence.c   Fri Apr 22 16:36:31 2005
@@ -22,7 +22,7 @@
  */
 /** @file
  * @brief Handlers for SILENCE command.
- * @version $Id: m_silence.c,v 1.10 2005/02/19 03:09:29 entrope Exp $
+ * @version $Id: m_silence.c,v 1.11 2005/04/22 23:36:31 entrope Exp $
  */
 
 #include "config.h"
@@ -60,7 +60,7 @@
  * @return The new ban entry on success, NULL on failure.
  */
 static struct Ban *
-apply_silence(struct Client *sptr, const char *mask)
+apply_silence(struct Client *sptr, char *mask)
 {
   struct Ban *sile;
   int flags;
@@ -84,7 +84,7 @@
   }
 
   /* Make the silence, set flags, and apply it. */
-  sile = make_ban(mask);
+  sile = make_ban(pretty_mask(mask));
   sile->flags |= flags;
   return apply_ban(&cli_user(sptr)->silence, sile, 1) ? NULL : sile;
 }
----------------------- End of diff -----------------------
_______________________________________________
Patches mailing list
[email protected]
http://undernet.sbg.org/mailman/listinfo/patches

Reply via email to