Skip to content
Snippets Groups Projects
Commit 622034ef authored by Geo Ster's avatar Geo Ster
Browse files

Stop leaking memory

* The handler table is dynamically but the memory never gets
deallocated. Plug the leak by clearing any memory in the destructor ;)
parent 52b34632
No related branches found
No related tags found
No related merge requests found
......@@ -24,6 +24,14 @@ namespace common
Emulator::~Emulator()
{
/* Clean up handler table */
for (auto ptr : handlers)
{
if (ptr != nullptr)
delete ptr;
}
/* Cleanup BIOS memory */
delete[] bios;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment