summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortrystan trystan@31f1291d-b8d6-0310-a050-a5561fc1590b <trystan trystan@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864>2005-01-16 20:11:15 +0000
committertrystan trystan@31f1291d-b8d6-0310-a050-a5561fc1590b <trystan trystan@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864>2005-01-16 20:11:15 +0000
commit26bd7c0418651493c50040c769e7f94b13097283 (patch)
tree7cfa41a9656dd727729a4f19a9833ebe0bdd6cd0
parent4bf0358e8ff03a9b9a31639a3d057f0d679c2f7d (diff)
BUILD : 1.7.7 (542) BUGS : 263 NOTES : BotServ bots would flood if they were attempting to reset modes on themselves ie.. (-oooooo), this fix makes them check if they set the mode last on themselves, if so it ignores and continues. This should also fix if you did -v to a bot as it would says non-existant user
git-svn-id: svn://svn.anope.org/anope/trunk@542 31f1291d-b8d6-0310-a050-a5561fc1590b git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@395 5417fbe8-f217-4b02-8779-1006273d7864
-rw-r--r--Changes1
-rw-r--r--src/channels.c19
-rw-r--r--version.log8
3 files changed, 23 insertions, 5 deletions
diff --git a/Changes b/Changes
index 33a1878f3..e6cd8fe7e 100644
--- a/Changes
+++ b/Changes
@@ -2,6 +2,7 @@ Anope Version S V N
-------------------
Provided by Anope Dev. <dev@anope.org> - 2005
01/16 A Ulines Servers are now except from NOJOIN bans [#281]
+01/16 F BS bots no longer flood resetting modes if its the same mode. [#263]
01/16 F IRCops are now except from KillonSQline and KillonSGline [#274]
01/16 F BS Badwords had a false positives if BSCaseSensitive wass enabled [#277]
01/15 F Updated typo in example.conf. [#279]
diff --git a/src/channels.c b/src/channels.c
index 5fd2340d1..240f308a0 100644
--- a/src/channels.c
+++ b/src/channels.c
@@ -180,6 +180,9 @@ void chan_set_modes(const char *source, Channel * chan, int ac, char **av,
CBMode *cbm;
CMMode *cmm;
CUMode *cum;
+ int botcheck = 0;
+ unsigned char botmode;
+ BotInfo *bi;
if (debug)
alog("debug: Changing modes for %s to %s", chan->name,
@@ -215,11 +218,19 @@ void chan_set_modes(const char *source, Channel * chan, int ac, char **av,
av++;
if ((cum->flags & CUF_PROTECT_BOTSERV) && !add) {
- BotInfo *bi;
-
if ((bi = findbot(*av))) {
- anope_cmd_mode(bi->nick, chan->name, "+%c %s", mode,
- bi->nick);
+ if (!botmode || botmode != mode) {
+ anope_cmd_mode(bi->nick, chan->name, "+%c %s",
+ mode, bi->nick);
+ botmode = mode;
+ continue;
+ } else {
+ botmode = mode;
+ continue;
+ }
+ }
+ } else {
+ if ((bi = findbot(*av))) {
continue;
}
}
diff --git a/version.log b/version.log
index 87d38c9c8..07b06a09c 100644
--- a/version.log
+++ b/version.log
@@ -8,10 +8,16 @@
VERSION_MAJOR="1"
VERSION_MINOR="7"
VERSION_PATCH="7"
-VERSION_BUILD="541"
+VERSION_BUILD="542"
# $Log$
#
+# BUILD : 1.7.7 (542)
+# BUGS : 263
+# NOTES : BotServ bots would flood if they were attempting to reset modes on themselves ie.. (-oooooo), this fix makes
+# them check if they set the mode last on themselves, if so it ignores and continues. This should also fix if you did -v to a bot as it would
+# says non-existant user
+#
# BUILD : 1.7.7 (541)
# BUGS : 274, 281
# NOTES : IRCops are not killed on sqline/sgline when set KillOnSQline or KillOnSGline are enabled, made it so uline