소스 검색

Coverity findings: fix resource leak in PlyLoader.cpp.

Kim Kulling 10 년 전
부모
커밋
7c3475c002
1개의 변경된 파일1개의 추가작업 그리고 0개의 파일을 삭제
  1. 1 0
      code/PlyLoader.cpp

+ 1 - 0
code/PlyLoader.cpp

@@ -312,6 +312,7 @@ void PLYImporter::ConvertMeshes(std::vector<PLY::Face>* avFaces,
             p_pcOut->mNumVertices = iNum;
             if( 0 == iNum ) {     // nothing to do 
                 delete[] aiSplit; // cleanup
+                delete p_pcOut;
                 return;
             }
             p_pcOut->mVertices = new aiVector3D[iNum];