diff options
author | Willem Jan Palenstijn | 2009-02-19 20:47:06 +0000 |
---|---|---|
committer | Willem Jan Palenstijn | 2009-02-19 20:47:06 +0000 |
commit | 09c38836120def69debed41e58c1c75488835f87 (patch) | |
tree | cd404689421b78579257fd1d5e0bb114d4583172 | |
parent | 2595783e9fc522e5c6d37672b230b409024e34e5 (diff) | |
download | scummvm-rg350-09c38836120def69debed41e58c1c75488835f87.tar.gz scummvm-rg350-09c38836120def69debed41e58c1c75488835f87.tar.bz2 scummvm-rg350-09c38836120def69debed41e58c1c75488835f87.zip |
don't give up scanning files after one potential executable (such as sierra.ico...)
svn-id: r38563
-rw-r--r-- | engines/sci/detection.cpp | 24 |
1 files changed, 7 insertions, 17 deletions
diff --git a/engines/sci/detection.cpp b/engines/sci/detection.cpp index 5af98d96c8..c37b0d1575 100644 --- a/engines/sci/detection.cpp +++ b/engines/sci/detection.cpp @@ -1716,29 +1716,19 @@ const ADGameDescription *SciMetaEngine::fallbackDetect(const Common::FSList &fsl Common::SeekableReadStream *fileStream = file->createReadStream(); bool isExe = isGameExe(fileStream); - if (isExe) { - if (!readSciVersionFromExe(fileStream, &exeVersion)) { - printf("Error while reading SCI version from the game executable\n"); - delete fileStream; - return 0; - } else { - // All ok, we got the version from the executable successfully - foundExe = true; - delete fileStream; - break; - } - } else { - printf("The original game executable seems to be corrupted\n"); + if (isExe && readSciVersionFromExe(fileStream, &exeVersion)) { + // All ok, we got the version from the executable successfully + foundExe = true; delete fileStream; - return 0; - } - + break; + } + delete fileStream; } } if (!foundExe) { - printf("The original game executable wasn't found\n"); + printf("No original game executable containing a version number was found\n"); return 0; } |