aboutsummaryrefslogtreecommitdiff
path: root/scumm
diff options
context:
space:
mode:
authorRobert Göffringmann2004-12-09 15:06:49 +0000
committerRobert Göffringmann2004-12-09 15:06:49 +0000
commit0d7ab01640a2209167272936c624c32142131993 (patch)
treed9ec454332093ae1a6c4ca7f9b2954c5d4852e78 /scumm
parent58bf9028b16a1a6d125baa79b223de5e2a5aa0e0 (diff)
downloadscummvm-rg350-0d7ab01640a2209167272936c624c32142131993.tar.gz
scummvm-rg350-0d7ab01640a2209167272936c624c32142131993.tar.bz2
scummvm-rg350-0d7ab01640a2209167272936c624c32142131993.zip
Pass subdirectories to gamedetector functions
svn-id: r16002
Diffstat (limited to 'scumm')
-rw-r--r--scumm/scumm.cpp16
1 files changed, 9 insertions, 7 deletions
diff --git a/scumm/scumm.cpp b/scumm/scumm.cpp
index 365e3d4e56..18f746f73c 100644
--- a/scumm/scumm.cpp
+++ b/scumm/scumm.cpp
@@ -2678,13 +2678,15 @@ DetectedGameList Engine_SCUMM_detectGames(const FSList &fslist) {
// Iterate over all files in the given directory
for (FSList::const_iterator file = fslist.begin(); file != fslist.end(); ++file) {
- const char *name = file->displayName().c_str();
-
- if (0 == scumm_stricmp(detectName, name)) {
- // Match found, add to list of candidates, then abort inner loop.
- detectedGames.push_back(g->toGameSettings());
- fileSet.addKey(file->path());
- break;
+ if (!file->isDirectory()) {
+ const char *name = file->displayName().c_str();
+
+ if (0 == scumm_stricmp(detectName, name)) {
+ // Match found, add to list of candidates, then abort inner loop.
+ detectedGames.push_back(g->toGameSettings());
+ fileSet.addKey(file->path());
+ break;
+ }
}
}
}