summaryrefslogtreecommitdiff
path: root/indra/newview/llappearancemgr.cpp
diff options
context:
space:
mode:
authorErik Kundiman <erik@megapahit.org>2025-07-10 15:03:55 +0800
committerErik Kundiman <erik@megapahit.org>2025-07-10 15:03:55 +0800
commita9b5563065fa4768072bbe2ffc023cc73675d701 (patch)
treec96432f2707e906ea827aad3e466c92e0c6c552f /indra/newview/llappearancemgr.cpp
parent651df17f2c76b60b52c56a7cc35787a8ea87b246 (diff)
Fix crash from trying to detach alpha
Diffstat (limited to 'indra/newview/llappearancemgr.cpp')
-rw-r--r--indra/newview/llappearancemgr.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/indra/newview/llappearancemgr.cpp b/indra/newview/llappearancemgr.cpp
index 504582f2d7..242d407219 100644
--- a/indra/newview/llappearancemgr.cpp
+++ b/indra/newview/llappearancemgr.cpp
@@ -4160,7 +4160,8 @@ void LLAppearanceMgr::removeItemsFromAvatar(const uuid_vec_t& ids_to_remove, nul
for (uuid_vec_t::const_iterator it = ids_to_remove.begin(); it != ids_to_remove.end(); ++it)
{
const LLUUID& id_to_remove = *it;
- if (gAgentAvatarp->getWornAttachment(id_to_remove)->isLocked()) continue;
+ auto attachment = gAgentAvatarp->getWornAttachment(id_to_remove);
+ if (attachment && attachment->isLocked()) continue;
const LLUUID& linked_item_id = gInventory.getLinkedItemID(id_to_remove);
LLViewerInventoryItem *item = gInventory.getItem(linked_item_id);
if (item && item->getType() == LLAssetType::AT_OBJECT)