From d416fe874e9422219a239bcba6afeb72a06c23cb Mon Sep 17 00:00:00 2001 From: Kim Kulling Date: Sat, 16 Jun 2018 10:32:43 +0200 Subject: [PATCH] Update XFileParser.cpp Fix compiler warnings. --- code/XFileParser.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/XFileParser.cpp b/code/XFileParser.cpp index 86074e256..e7bf8518c 100644 --- a/code/XFileParser.cpp +++ b/code/XFileParser.cpp @@ -472,7 +472,7 @@ void XFileParser::ParseDataObjectMesh( Mesh* pMesh) Face& face = pMesh->mPosFaces[a]; for (unsigned int b = 0; b < numIndices; ++b) { const int idx( ReadInt() ); - if ( idx <= numVertices ) { + if ( static_cast( idx ) <= numVertices ) { face.mIndices.push_back( idx ); } } @@ -1309,7 +1309,7 @@ unsigned int XFileParser::ReadInt() --mBinaryNumCount; const size_t len( mEnd - mP ); - if ( mEnd - mP >= 4) { + if ( len >= 4) { return ReadBinDWord(); } else { mP = mEnd;