diff --git a/code/SplitByBoneCountProcess.cpp b/code/SplitByBoneCountProcess.cpp index b33b6d95c..6faf11086 100644 --- a/code/SplitByBoneCountProcess.cpp +++ b/code/SplitByBoneCountProcess.cpp @@ -393,7 +393,7 @@ void SplitByBoneCountProcess::UpdateNode( aiNode* pNode) const newMeshList.insert( newMeshList.end(), replaceMeshes.begin(), replaceMeshes.end()); } - delete pNode->mMeshes; + delete [] pNode->mMeshes; pNode->mNumMeshes = static_cast(newMeshList.size()); pNode->mMeshes = new unsigned int[pNode->mNumMeshes]; std::copy( newMeshList.begin(), newMeshList.end(), pNode->mMeshes);