- fixed two memory leaks.

This commit is contained in:
Christoph Oelckers 2022-12-03 20:35:27 +01:00
parent 169139c22c
commit e8d7e0227b
2 changed files with 3 additions and 0 deletions

View file

@ -443,4 +443,5 @@ void LoadHexFont(const char* filename)
auto hexfont = resf->FindLump("newconsolefont.hex");
if (hexfont == nullptr) I_FatalError("Unable to find newconsolefont.hex in %s", filename);
hexdata.ParseDefinition(hexfont);
delete resf;
}

View file

@ -372,7 +372,9 @@ void FLevelLocals::ClearLevelData(bool fullgc)
Behaviors.UnloadModules();
localEventManager->Shutdown();
if (aabbTree) delete aabbTree;
if (levelMesh) delete levelMesh;
aabbTree = nullptr;
levelMesh = nullptr;
if (screen)
screen->SetAABBTree(nullptr);
}