소스 검색

Remove assertion in ObjFileImporter

This assertion is already handled by an exception, and could lead to a
crash when parsing an ill-formed OBJ file.
Alexandre Avenel 7 년 전
부모
커밋
20ef807982
1개의 변경된 파일0개의 추가작업 그리고 1개의 파일을 삭제
  1. 0 1
      code/ObjFileImporter.cpp

+ 0 - 1
code/ObjFileImporter.cpp

@@ -474,7 +474,6 @@ void ObjFileImporter::createVertexArray(const ObjFile::Model* pModel,
             if ( !pModel->m_TextureCoord.empty() && vertexIndex < pSourceFace->m_texturCoords.size())
             if ( !pModel->m_TextureCoord.empty() && vertexIndex < pSourceFace->m_texturCoords.size())
             {
             {
                 const unsigned int tex = pSourceFace->m_texturCoords.at( vertexIndex );
                 const unsigned int tex = pSourceFace->m_texturCoords.at( vertexIndex );
-                ai_assert( tex < pModel->m_TextureCoord.size() );
 
 
                 if ( tex >= pModel->m_TextureCoord.size() )
                 if ( tex >= pModel->m_TextureCoord.size() )
                     throw DeadlyImportError("OBJ: texture coordinate index out of range");
                     throw DeadlyImportError("OBJ: texture coordinate index out of range");