WINTERMUTE: Use hasSuffix instead of contains to verify file-extensions.

This commit is contained in:
Einar Johan Trøan Sømåen 2012-07-24 18:14:38 +02:00
parent 88fe4e3106
commit 579810d296

View File

@ -277,7 +277,7 @@ bool BaseFileManager::registerPackages() {
warning("Should register %s %s", (*it).getPath().c_str(), (*it).getName().c_str());
(*it).getChildren(files, Common::FSNode::kListFilesOnly);
for (Common::FSList::iterator fileIt = files.begin(); fileIt != files.end(); fileIt++) {
if (!fileIt->getName().contains(".dcp"))
if (!fileIt->getName().hasSuffix(".dcp"))
continue;
// Avoid registering all the language files
// TODO: Select based on the gameDesc.