Changed FilesystemNode::listDir to return a bool indicating its success (or failure)

svn-id: r22315
This commit is contained in:
Max Horn 2006-05-03 20:43:26 +00:00
parent 1902673ece
commit d016c353c5
15 changed files with 73 additions and 69 deletions

View file

@ -271,15 +271,13 @@ static void runDetectorTest() {
}
FilesystemNode dir(path);
if (!dir.isValid() || !dir.isDirectory()) {
FSList files;
if (!dir.listDir(files, FilesystemNode::kListAll)) {
printf(" ... invalid path, skipping\n");
continue;
}
FSList files = dir.listDir(FilesystemNode::kListAll);
DetectedGameList candidates(PluginManager::instance().detectGames(files));
DetectedGameList candidates(PluginManager::instance().detectGames(files));
bool gameidDiffers = false;
for (DetectedGameList::iterator x = candidates.begin(); x != candidates.end(); ++x) {
gameidDiffers |= scumm_stricmp(gameid.c_str(), x->gameid.c_str());