1
0
mirror of https://github.com/anope/anope.git synced 2026-06-29 18:36:38 +02:00

Properly store our clients internal channel status's and burst them if needed.

Also made Flag::HasFlag use test() instead of operator[] to catch errors, and fixed an out of bounds access to a
Flags
bitset causing crashes on some systems.
This commit is contained in:
Adam
2010-08-28 20:56:45 -04:00
parent 26ba944d55
commit e820e1af0d
12 changed files with 39 additions and 26 deletions
+3 -3
View File
@@ -28,9 +28,9 @@ std::map<ChannelModeName, ChannelMode *> ModeManager::ChannelModesByName;
/* Number of generic modes we support */
unsigned GenericChannelModes = 0, GenericUserModes = 0;
/* Default mlocked modes on */
Flags<ChannelModeName> DefMLockOn;
Flags<ChannelModeName, CMODE_END * 2> DefMLockOn;
/* Default mlocked modes off */
Flags<ChannelModeName> DefMLockOff;
Flags<ChannelModeName, CMODE_END * 2> DefMLockOff;
/* Map for default mlocked mode parameters */
std::map<ChannelModeName, Anope::string> DefMLockParams;
@@ -41,7 +41,7 @@ void SetDefaultMLock(ServerConfig *config)
DefMLockOn.ClearFlags();
DefMLockOff.ClearFlags();
DefMLockParams.clear();
Flags<ChannelModeName> *ptr = NULL;
Flags<ChannelModeName, CMODE_END * 2> *ptr = NULL;
Anope::string modes, param;
spacesepstream sep(config->MLock);