Fix memory leak when disbanding a Guild, removed from GuildMgr but never deleted. Due to the different ways of how Guild::Disband() and Guild::DeleteMember() are called, each call to these methods has a different way to delete the Guild if empty/invalid.
Valgrind log:
2,127 (240 direct, 1,887 indirect) bytes in 1 blocks are definitely lost in loss record 54 of 81
at operator new(unsigned long) (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
by guild_commandscript::HandleGuildCreateCommand(ChatHandler*, char const*) (cs_guild.cpp:91)
by ChatHandler::ExecuteCommandInTable(ChatCommand*, char const*, std::string const&) (Chat.cpp:339)
by ChatHandler::ExecuteCommandInTable(ChatCommand*, char const*, std::string const&) (Chat.cpp:320)
by ChatHandler::ParseCommands(char const*) (Chat.cpp:466)
by WorldSession::HandleMessagechatOpcode(WorldPacket&) (ChatHandler.cpp:217)
by WorldSession::Update(unsigned int, PacketFilter&) (WorldSession.cpp:317)
by World::UpdateSessions(unsigned int) (World.cpp:2632)
by World::Update(unsigned int) (World.cpp:1989)
by WorldRunnable::run() (WorldRunnable.cpp:60)
by ACE_Based::Thread::ThreadTask(void*) (Threading.cpp:186)
by ACE_OS_Thread_Adapter::invoke() (in /usr/lib/libACE-6.0.3.so)
Currently regulates the usage of CMSG_CHAR_ENUM only, but can be easily
extended to detect inappropriate network behaviour by using
AntiDOS.AllowOpcode in WorldSession's handlers.
- Remove config options: CONFIG_ALLOW_TWO_SIDE_INTERACTION_CHAT, CONFIG_ALLOW_TWO_SIDE_INTERACTION_MAIL, CONFIG_GM_LOG_TRADE, CONFIG_ALLOW_TWO_SIDE_ACCOUNTS, CONFIG_ALLOW_TWO_SIDE_WHO_LIST, CONFIG_ALLOW_GM_FRIEND, CONFIG_ALLOW_TWO_SIDE_ADD_FRIEND, CONFIG_SILENTLY_GM_JOIN_TO_CHANNEL
- Fix RBAC_PERM_SKIP_CHECK_CHAT_SPAM (Was checking spam for those that had the permission)
- Only check RBAC_PERM_TWO_SIDE_INTERACTION_CHAT for sender of whispers (Restores GM being able to whisper players)
- Only check RBAC_PERM_TWO_SIDE_INTERACTION_MAIL for sender
- Fix .ticket assign <Player>, with last RBAC change it was changed by mistake from Player to Account
- 'Skips character creation team mask check'
- 'Skips character creation class mask check'
- 'Skips character creation race mask check'
- 'Skips character creation reserved name check'
- 'Skips character creation heroic min level check'
- 'Creation of two side faction characters in same account' (Affected by global config option)
Ensure there's always valid character name data present, even for
characters that were manually inserted into the database, by adding
character name data on char enum if needed.
- some simplifications in reputation calculation
- removed aura in SPELL_AURA_LINKED should depends on SpellDifficulty
- remove some unneeded variable declarations when it's already declared
- remove some hacks
- fix some warnings in Lfg stuff
- some codestyle changes
There are still some issues that need to be fixed, for more info see CalendarHandler.cpp TODO part.
Some unblizzlike behaviour possible, we don't have a lot of sniffs.
Big thanks to @Warpten, he joined my project and helped a lot.
IMPORTANT NOTE: Read / append packed time functions in ByteBuffer.h are not correct, they need to be fixed in order to have event times accurate
Signed-off-by: Nay <dnpd.dd@gmail.com>
- Send correct events when modifiying Ranks (Add, modify, delete)
- Store money/slots withdraw, not remaining slots. This will update remaining slots/money properly.
- Reset daily slots/money withdraw for all members at same time, configurable
- Better debug messages