Skip to content

Commit

Permalink
MOHAWK: Don't allow string patterns when looking for resources
Browse files Browse the repository at this point in the history
The last pattern based query was removed from Riven
  • Loading branch information
bgK authored and sev- committed Jul 3, 2017
1 parent 08e6423 commit f29197e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions engines/mohawk/resource.cpp
Expand Up @@ -74,7 +74,7 @@ bool Archive::hasResource(uint32 tag, const Common::String &resName) const {
const ResourceMap &resMap = _types[tag];

for (ResourceMap::const_iterator it = resMap.begin(); it != resMap.end(); it++)
if (it->_value.name.matchString(resName, true))
if (it->_value.name.equalsIgnoreCase(resName))
return true;

return false;
Expand Down Expand Up @@ -113,7 +113,7 @@ uint16 Archive::findResourceID(uint32 tag, const Common::String &resName) const
const ResourceMap &resMap = _types[tag];

for (ResourceMap::const_iterator it = resMap.begin(); it != resMap.end(); it++)
if (it->_value.name.matchString(resName, true))
if (it->_value.name.equalsIgnoreCase(resName))
return it->_key;

return 0xFFFF;
Expand Down

0 comments on commit f29197e

Please sign in to comment.