1
0
mirror of https://github.com/OpenTTD/OpenTTD.git synced 2025-09-03 22:59:30 +00:00

Fix #7590: decrement allocated_size in ScriptAllocator::Free()

This commit is contained in:
glx
2019-05-13 21:55:02 +02:00
committed by glx22
parent de73c8f91c
commit aac4255d43

View File

@@ -93,6 +93,7 @@ struct ScriptAllocator {
{
if (p == nullptr) return;
free(p);
this->allocated_size -= size;
#ifdef SCRIPT_DEBUG_ALLOCATIONS
assert(this->allocations.at(p) == size);