From 4cc13c102d1ea6877f5bba5113a5cd5a96abcbc3 Mon Sep 17 00:00:00 2001 From: chanayane Date: Wed, 7 May 2025 22:14:29 +0200 Subject: [PATCH] fix potential crash if item doesn't exist in inventory --- indra/newview/aoengine.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/indra/newview/aoengine.cpp b/indra/newview/aoengine.cpp index a66c8885b8..677097427d 100644 --- a/indra/newview/aoengine.cpp +++ b/indra/newview/aoengine.cpp @@ -999,6 +999,13 @@ void AOEngine::playAnimation(const LLUUID& animation) } LLViewerInventoryItem* item = gInventory.getItem(animation); + + if (!item) + { + LL_WARNS("AOEngine") << "Inventory item for animation " << animation << " not found." << LL_ENDL; + return; + } + AOSet::AOAnimation anim; anim.mName = item->LLInventoryItem::getName(); anim.mInventoryUUID = item->getUUID();