From 720ac4846b4505fbec4d67d34ad007df318ac86f Mon Sep 17 00:00:00 2001 From: Theak Date: Sun, 22 Sep 2019 10:12:19 +0100 Subject: [PATCH] Fix: memory leak in gltf2 importer (fixes #2661) --- code/glTF2/glTF2Importer.cpp | 1 - 1 file changed, 1 deletion(-) diff --git a/code/glTF2/glTF2Importer.cpp b/code/glTF2/glTF2Importer.cpp index d1871ce0e..9b6ef3693 100644 --- a/code/glTF2/glTF2Importer.cpp +++ b/code/glTF2/glTF2Importer.cpp @@ -444,7 +444,6 @@ void glTF2Importer::ImportMeshes(glTF2::Asset& r) "\" does not match the vertex count"); continue; } - aim->mColors[c] = new aiColor4D[attr.color[c]->count]; attr.color[c]->ExtractData(aim->mColors[c]); } for (size_t tc = 0; tc < attr.texcoord.size() && tc < AI_MAX_NUMBER_OF_TEXTURECOORDS; ++tc) {