We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 596ece7 + 43cd406 commit 8c24656Copy full SHA for 8c24656
Server/Components/Objects/objects_impl.hpp
@@ -634,6 +634,8 @@ class PlayerObjectData final : public IPlayerObjectData
634
// Decrement the number of player objects using this ID. Once it hits 0 it can become global.
635
component_.decrementPlayerCounter(obj->getID());
636
}
637
+ // Explicitly clear PlayerObjects to avoid use-after-free when accessing this object from PlayerObject's destructor
638
+ storage.clear();
639
delete this;
640
641
0 commit comments