diff options
author | Cosmic Linden <cosmic@lindenlab.com> | 2023-11-08 14:51:48 -0800 |
---|---|---|
committer | Cosmic Linden <cosmic@lindenlab.com> | 2023-11-09 13:54:42 -0800 |
commit | 4ad7e250f3302a6158378a5acbf88ac27dd95ced (patch) | |
tree | 29bc41cb5ee3965fc4fa888cca0117a9e09ba128 /indra | |
parent | 0d50f29697f999c91a4bed702b9bae281b247250 (diff) |
SL-20553: Fix assert
Diffstat (limited to 'indra')
-rw-r--r-- | indra/newview/llmaterialeditor.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/indra/newview/llmaterialeditor.cpp b/indra/newview/llmaterialeditor.cpp index 2f31889f32..2f4c29446e 100644 --- a/indra/newview/llmaterialeditor.cpp +++ b/indra/newview/llmaterialeditor.cpp @@ -1878,7 +1878,8 @@ bool can_use_objects_material(LLSelectedTEGetMatData& func, const std::vector<Pe // Look for the item to base permissions off of item_out = nullptr; - if (func.mMaterialId != LLGLTFMaterialList::BLANK_MATERIAL_ASSET_ID) + const bool blank_material = func.mMaterialId == LLGLTFMaterialList::BLANK_MATERIAL_ASSET_ID; + if (!blank_material) { LLAssetIDMatchesWithPerms item_has_perms(func.mMaterialId, ops); if (item_source == ItemSource::OBJECT) @@ -1970,7 +1971,7 @@ bool can_use_objects_material(LLSelectedTEGetMatData& func, const std::vector<Pe // -Cosmic,2023-08-07 if (item_source == ItemSource::AGENT) { - llassert(item_out); + llassert(blank_material || item_out); // See comment at ItemSource::AGENT definition permissions_out.set(item_permissions); } |