Fix infinite loop in addToLevList

This commit is contained in:
scrawl 2015-11-05 01:18:01 +01:00
parent 489addf772
commit 8e4e4e5e38

View file

@ -37,7 +37,7 @@ namespace
void addToLevList(ESM::LevelledListBase* list, const std::string& itemId, int level)
{
for (std::vector<ESM::LevelledListBase::LevelItem>::iterator it = list->mList.begin(); it != list->mList.end();)
for (std::vector<ESM::LevelledListBase::LevelItem>::iterator it = list->mList.begin(); it != list->mList.end(); ++it)
{
if (it->mLevel == level && itemId == it->mId)
return;