From 44ea9490797ce0e984aadbf438c7a2aceef5ddf0 Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Tue, 27 Feb 2024 23:00:37 +0200 Subject: Issue#900 Crash at LLInventoryAddItemByAssetObserver --- indra/newview/llinventoryobserver.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'indra/newview') diff --git a/indra/newview/llinventoryobserver.cpp b/indra/newview/llinventoryobserver.cpp index fe067b621a..e1eaa18206 100644 --- a/indra/newview/llinventoryobserver.cpp +++ b/indra/newview/llinventoryobserver.cpp @@ -566,8 +566,12 @@ void LLInventoryAddItemByAssetObserver::changed(U32 mask) for (uuid_set_t::iterator it = added.begin(); it != added.end(); ++it) { LLInventoryItem *item = gInventory.getItem(*it); + if (!item) + { + continue; + } const LLUUID& asset_uuid = item->getAssetUUID(); - if (item && item->getUUID().notNull() && asset_uuid.notNull()) + if (item->getUUID().notNull() && asset_uuid.notNull()) { if (isAssetWatched(asset_uuid)) { -- cgit v1.2.3