Sfoglia il codice sorgente

* Port [3579] to 1.2.14
* Fix checking for flood on hosts which are already ignored. (fixes #343)


svn: 3580

Bryan Drewery 18 anni fa
parent
commit
dcccdcabf2
2 ha cambiato i file con 4 aggiunte e 4 eliminazioni
  1. 1 0
      doc/UPDATES
  2. 3 4
      src/mod/server.mod/servmsg.c

+ 1 - 0
doc/UPDATES

@@ -63,6 +63,7 @@ Lines prefixed with '-' were disabled before release and are not finished, or ar
 * Bot no longer requires (or uses) '-B' to spawn bots. (now: ./binary <botnick>)
 * Fixed +take opping the wrong clients due to desync (+take now sets +bitch)
 * Fix cmd/dcc prefix leaking to -p users (when chat is off) (fixes #376)
+* Fix checking for flood on hosts which are already ignored. (fixes #343)
 
 1.2.13 - http://wraith.shatow.net/milestone/1.2.13
 * Fix cmd_chanset accepting invalid flags

+ 3 - 4
src/mod/server.mod/servmsg.c

@@ -568,7 +568,7 @@ static int gotmsg(char *from, char *msg)
       if (auth_prefix[0])
         auth = Auth::Find(uhost);
 
-      if (!auth)
+      if (!auth && !ignoring)
         detect_flood(nick, uhost, from, FLOOD_PRIVMSG);
       my_code = newsplit(&msg);
       rmspace(msg);
@@ -684,11 +684,10 @@ static int gotnotice(char *from, char *msg)
 	/* Hidden `250' connection count message from server */
 	if (strncmp(msg, "Highest connection count:", 25))
 	  putlog(LOG_SERV, "*", "-NOTICE- %s", msg);
-      } else {
+      } else if (!ignoring) {
         detect_flood(nick, uhost, from, FLOOD_NOTICE);
         u = get_user_by_host(from);
-        if (!ignoring)
-  	      putlog(LOG_MSGS, "*", "-%s (%s)- %s", nick, uhost, msg);
+        putlog(LOG_MSGS, "*", "-%s (%s)- %s", nick, uhost, msg);
       }
     }
   }