Don't list deleted refs in CellStore::foreach

This commit is contained in:
scrawl 2013-11-27 18:43:42 +01:00
parent 49ea1aae67
commit a8c838b53a

View file

@ -140,9 +140,12 @@ namespace MWWorld
{ {
for (typename List::List::iterator iter (list.mList.begin()); iter!=list.mList.end(); for (typename List::List::iterator iter (list.mList.begin()); iter!=list.mList.end();
++iter) ++iter)
{
if (!iter->mData.getCount())
continue;
if (!functor (iter->mRef, iter->mData)) if (!functor (iter->mRef, iter->mData))
return false; return false;
}
return true; return true;
} }