diff --git a/src/scripting/vm/vmframe.cpp b/src/scripting/vm/vmframe.cpp index 08559445eb..09192cbfe1 100644 --- a/src/scripting/vm/vmframe.cpp +++ b/src/scripting/vm/vmframe.cpp @@ -272,6 +272,7 @@ VMFrameStack::~VMFrameStack() next = block->NextBlock; delete[] (VM_UBYTE *)block; } + Blocks = NULL; } if (UnusedBlocks != NULL) { @@ -281,9 +282,8 @@ VMFrameStack::~VMFrameStack() next = block->NextBlock; delete[] (VM_UBYTE *)block; } + UnusedBlocks = NULL; } - Blocks = NULL; - UnusedBlocks = NULL; } //=========================================================================== @@ -608,4 +608,4 @@ ADD_STAT(VM) VMCycles[0].Reset(); VMCalls[0] = 0; return FStringf("VM time in last 10 tics: %f ms, %d calls", added, addedc); -} \ No newline at end of file +}