- fixed voxels leaking memory.

This commit is contained in:
Christoph Oelckers 2019-12-25 08:57:58 +01:00
parent efe4261932
commit 745d78d8d7
5 changed files with 18 additions and 1 deletions

View file

@ -842,6 +842,11 @@ void voxfree(voxmodel_t *m)
DO_FREE_AND_NULL(m->mytex);
DO_FREE_AND_NULL(m->quad);
for (auto& tex : m->texid)
{
if (tex) delete tex;
tex = nullptr;
}
Xfree(m);
}