From 1bbae197792549269149a1a261d1c361cf8adcd7 Mon Sep 17 00:00:00 2001 From: Kim Kulling Date: Tue, 11 Aug 2020 20:28:12 +0200 Subject: [PATCH] Fix leak --- test/unit/Common/utStandardShapes.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/unit/Common/utStandardShapes.cpp b/test/unit/Common/utStandardShapes.cpp index 8b333b08d..8469fecd6 100644 --- a/test/unit/Common/utStandardShapes.cpp +++ b/test/unit/Common/utStandardShapes.cpp @@ -47,10 +47,11 @@ TEST_F( utStandardShapes, testMakeMesh ) { // Make mesh const auto numIndicesPerPrimitive = 3; - auto aiMeshPtr = Assimp::StandardShapes::MakeMesh(positions, numIndicesPerPrimitive); + aiMesh *aiMeshPtr = Assimp::StandardShapes::MakeMesh(positions, numIndicesPerPrimitive); // The mNumIndices member of the second face is now incorrect const auto& face = aiMeshPtr->mFaces[0]; EXPECT_EQ(face.mNumIndices, numIndicesPerPrimitive); + delete aiMeshPtr; }