1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-02-13 11:39:47 +00:00

Use a normal binary search

This commit is contained in:
Alexander "Ace" Olofsson 2012-03-29 21:27:37 +02:00
parent ce38876a74
commit c3944d3e1a

View file

@ -116,12 +116,7 @@ class DirArchive: public Ogre::FileSystemArchive
}
mrComparer comp(delimiter, copy.size() - delimiter-1);
std::vector<std::string>::iterator found = std::lower_bound(current.begin(), current.end(), copy, comp);
if (found != current.end() && !(comp(copy, current.front())))
return true;
return false;
return std::binary_search(current.begin(), current.end(), copy, comp);
}
public: