Browse Source

Merge branch 'maint'

* maint:
  On a nick change, clear any pending modes, but still check for actions on the new nick!uhost.
  Remove bogus comment
Bryan Drewery 10 years ago
parent
commit
c0f96c398a
2 changed files with 5 additions and 13 deletions
  1. 1 0
      doc/UPDATES.md
  2. 4 13
      src/mod/irc.mod/chan.cc

+ 1 - 0
doc/UPDATES.md

@@ -14,6 +14,7 @@
   * Fix bot not auto-opping after just connecting.
   * Fix invites not being applied in -dynamicinvites channels when +i is set.
   * Fix not handling auto-op in minutely channel rechecks.
+  * Fix auto-voice and auto-op not applying after a nick change.
 
 # 1.4.6
   * Disable demo TCL support by default to prevent confusion during build.

+ 4 - 13
src/mod/irc.mod/chan.cc

@@ -3074,22 +3074,13 @@ static int gotnick(char *from, char *msg)
 
       detect_chan_flood(m, from, chan, FLOOD_NICK);
 
-      /* don't fill the serverqueue with modes or kicks in a nickflood */
-      if (chan_sentkick(m) || chan_sentdeop(m) || chan_sentop(m) ||
-	  chan_sentdevoice(m) || chan_sentvoice(m))
-	m->flags |= STOPCHECK;
       /* Any pending kick or mode to the old nick is lost. */
-	m->flags &= ~(SENTKICK | SENTDEOP | SENTOP |
-		      SENTVOICE | SENTDEVOICE);
-
-
-      /* make sure they stay devoiced if EVOICE! */
+      m->flags &= ~(SENTKICK | SENTDEOP | SENTOP |
+          SENTVOICE | SENTDEVOICE);
 
       /* nick-ban or nick is +k or something? */
-      if (!chan_stopcheck(m)) {
-	get_user_flagrec(m->user, &fr, chan->dname, chan);
-	check_this_member(chan, m->nick, &fr);
-      }
+      get_user_flagrec(m->user, &fr, chan->dname, chan);
+      check_this_member(chan, m->nick, &fr);
     }
   }
   return 0;