diff --git a/code/AssetLib/glTF2/glTF2Asset.inl b/code/AssetLib/glTF2/glTF2Asset.inl index 389a05199..a8d4f2d98 100644 --- a/code/AssetLib/glTF2/glTF2Asset.inl +++ b/code/AssetLib/glTF2/glTF2Asset.inl @@ -383,6 +383,7 @@ unsigned int LazyDict::Remove(const char *id) { mAsset.mUsedIds[id] = false; mObjsById.erase(id); mObjsByOIndex.erase(index); + delete mObjs[index]; mObjs.erase(mObjs.begin() + index); //update index of object in mObjs;