mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-18 00:18:43 +01:00
Scripts/Commands: Remove .debug asan outofbounds, because having reachable code that essentially says __builtin_unreachable in the core is making me twitchy.
This commit is contained in:
2
sql/updates/world/3.3.5/2020_08_17_00_world.sql
Normal file
2
sql/updates/world/3.3.5/2020_08_17_00_world.sql
Normal file
@@ -0,0 +1,2 @@
|
||||
--
|
||||
DELETE FROM `command` WHERE `name`='debug asan outofbounds';
|
||||
@@ -81,7 +81,6 @@ public:
|
||||
static std::vector<ChatCommand> debugAsanCommandTable =
|
||||
{
|
||||
{ "memoryleak", rbac::RBAC_PERM_COMMAND_DEBUG_ASAN, true, &HandleDebugMemoryLeak, "" },
|
||||
{ "outofbounds", rbac::RBAC_PERM_COMMAND_DEBUG_ASAN, true, &HandleDebugOutOfBounds, "" },
|
||||
};
|
||||
static std::vector<ChatCommand> debugCommandTable =
|
||||
{
|
||||
@@ -1900,15 +1899,6 @@ public:
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool HandleDebugOutOfBounds(ChatHandler* handler, CommandArgs* /*args*/)
|
||||
{
|
||||
uint8 stack_array[10] = {};
|
||||
int size = 10;
|
||||
|
||||
handler->PSendSysMessage("Triggered an array out of bounds read at address %p, value %u", stack_array + size, stack_array[size]);
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool HandleDebugMemoryLeak(ChatHandler* handler, CommandArgs* /*args*/)
|
||||
{
|
||||
uint8* leak = new uint8();
|
||||
|
||||
Reference in New Issue
Block a user