mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-25 06:35:30 +00:00
Don't crash when trying to delete a reference that doesn't exist anymore
This commit is contained in:
parent
5af89a9e8f
commit
3f8a69b4ad
@ -43,7 +43,8 @@ namespace MWWorld
|
|||||||
// Skip this when reference was deleted.
|
// Skip this when reference was deleted.
|
||||||
// TODO: Support respawning references, in this case, we need to track it somehow.
|
// TODO: Support respawning references, in this case, we need to track it somehow.
|
||||||
if (ref.mDeleted) {
|
if (ref.mDeleted) {
|
||||||
mList.erase(iter);
|
if (iter != mList.end())
|
||||||
|
mList.erase(iter);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user