Fix #7590: decrement allocated_size in ScriptAllocator::Free()
This commit is contained in:
@@ -93,6 +93,7 @@ struct ScriptAllocator {
|
|||||||
{
|
{
|
||||||
if (p == nullptr) return;
|
if (p == nullptr) return;
|
||||||
free(p);
|
free(p);
|
||||||
|
this->allocated_size -= size;
|
||||||
|
|
||||||
#ifdef SCRIPT_DEBUG_ALLOCATIONS
|
#ifdef SCRIPT_DEBUG_ALLOCATIONS
|
||||||
assert(this->allocations.at(p) == size);
|
assert(this->allocations.at(p) == size);
|
||||||
|
Reference in New Issue
Block a user