From b0ebad8b8322feb96908395fb931cdacce1ab8dd Mon Sep 17 00:00:00 2001 From: Koncord Date: Wed, 22 Feb 2017 16:30:07 +0800 Subject: [PATCH] [Client] Fix crash on Linux --- apps/openmw/mwworld/cellstore.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/openmw/mwworld/cellstore.cpp b/apps/openmw/mwworld/cellstore.cpp index 99545a64f..59fa1f5e2 100644 --- a/apps/openmw/mwworld/cellstore.cpp +++ b/apps/openmw/mwworld/cellstore.cpp @@ -650,7 +650,8 @@ namespace MWWorld loadRef (ref, deleted, refNumToID); } - setLastRefNumIndex(refNumToID.rbegin()->first.mIndex); + if(refNumToID.size() != 0) + setLastRefNumIndex(refNumToID.rbegin()->first.mIndex); updateMergedRefs(); }