diff --git a/code/Importer.cpp b/code/Importer.cpp index 06f04b0ce..f4c3da7cc 100644 --- a/code/Importer.cpp +++ b/code/Importer.cpp @@ -991,7 +991,7 @@ const aiScene* Importer::ReadFile( const char* _pFile, unsigned int pFlags) // not so bad yet ... try format auto detection. const std::string::size_type s = pFile.find_last_of('.'); if (s != std::string::npos) { - DefaultLogger::get()->info("File extension now known, trying signature-based detection"); + DefaultLogger::get()->info("File extension not known, trying signature-based detection"); for( unsigned int a = 0; a < pimpl->mImporter.size(); a++) { if( pimpl->mImporter[a]->CanRead( pFile, pimpl->mIOHandler, true)) { diff --git a/code/Q3BSPFileImporter.cpp b/code/Q3BSPFileImporter.cpp index a4731f2a9..9c884053b 100644 --- a/code/Q3BSPFileImporter.cpp +++ b/code/Q3BSPFileImporter.cpp @@ -151,10 +151,7 @@ Q3BSPFileImporter::~Q3BSPFileImporter() } std::vector *pCurFaceArray = (*it).second; - if ( NULL != pCurFaceArray ) - { - delete pCurFaceArray; - } + delete pCurFaceArray; } m_MaterialLookupMap.clear(); } @@ -163,13 +160,11 @@ Q3BSPFileImporter::~Q3BSPFileImporter() // Returns true, if the loader can read this. bool Q3BSPFileImporter::CanRead( const std::string& rFile, IOSystem* pIOHandler, bool checkSig ) const { - bool isBSPData = false; - if ( checkSig ) - { - isBSPData = SimpleExtensionCheck( rFile, Q3BSPExtension .c_str() ); + if(!checkSig) { + return SimpleExtensionCheck( rFile, Q3BSPExtension .c_str() ); } - - return isBSPData; + // TODO perhaps add keyword based detection + return false; } // ------------------------------------------------------------------------------------------------