From 8ead80e6e5bdbbc7271b45dd29997548c38c7a53 Mon Sep 17 00:00:00 2001
From: Brad Kittenbrink <brad@lindenlab.com>
Date: Wed, 19 Oct 2022 15:32:18 -0700
Subject: [PATCH] Xcode compat fix for SL-18105 material overrides

---
 indra/llprimitive/lltextureentry.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/indra/llprimitive/lltextureentry.h b/indra/llprimitive/lltextureentry.h
index 2c932a10dfe..8dc3434a01a 100644
--- a/indra/llprimitive/lltextureentry.h
+++ b/indra/llprimitive/lltextureentry.h
@@ -204,7 +204,7 @@ class LLTextureEntry
 
     // GLTF render material
     // nuanced behavior here -- if there is no render material, fall back to getGLTFMaterial, but ONLY for the getter, not the setter
-    LLGLTFMaterial* getGLTFRenderMaterial() const { return mGLTFRenderMaterial.notNull() ? mGLTFRenderMaterial : getGLTFMaterial(); }
+    LLGLTFMaterial* getGLTFRenderMaterial() const { return mGLTFRenderMaterial.notNull() ? mGLTFRenderMaterial.get() : getGLTFMaterial(); }
     S32 setGLTFRenderMaterial(LLGLTFMaterial* mat);
 
 public:
-- 
GitLab