From 8812705838dc1dd3efc80be04a9c9fb95d83e3b4 Mon Sep 17 00:00:00 2001 From: Andrei Kortunov Date: Fri, 5 Aug 2022 20:10:09 +0400 Subject: [PATCH] Avoid possible null dereference - throw an exception instead --- apps/openmw/mwgui/spellmodel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/openmw/mwgui/spellmodel.cpp b/apps/openmw/mwgui/spellmodel.cpp index 455f167415..b241570cfd 100644 --- a/apps/openmw/mwgui/spellmodel.cpp +++ b/apps/openmw/mwgui/spellmodel.cpp @@ -56,7 +56,7 @@ namespace MWGui if (effectId != -1) { const ESM::MagicEffect *magicEffect = - store.get().search(effectId); + store.get().find(effectId); std::string effectIDStr = ESM::MagicEffect::effectIdToString(effectId); std::string fullEffectName = wm->getGameSettingString(effectIDStr, "");