summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorDave Parks <davep@lindenlab.com>2022-02-24 13:04:40 -0600
committerDave Parks <davep@lindenlab.com>2022-02-24 13:04:40 -0600
commit658a30bd2e116149d3e6e6f937f9ad7f14983ce3 (patch)
tree7e7a35c81c521705a1e82f8c66596e53978f6acd /indra/newview
parent85e480616de4e741f9f34a396677002d86a1d660 (diff)
SL-16907 Potential fix for crash in updateSkinInfoMatrixPalette
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/lldrawpoolalpha.cpp2
-rw-r--r--indra/newview/llspatialpartition.h4
2 files changed, 4 insertions, 2 deletions
diff --git a/indra/newview/lldrawpoolalpha.cpp b/indra/newview/lldrawpoolalpha.cpp
index 963ea6ff8b..2bf8e9b911 100644
--- a/indra/newview/lldrawpoolalpha.cpp
+++ b/indra/newview/lldrawpoolalpha.cpp
@@ -795,7 +795,7 @@ void LLDrawPoolAlpha::renderAlpha(U32 mask, bool depth_only, bool rigged)
bool LLDrawPoolAlpha::uploadMatrixPalette(const LLDrawInfo& params)
{
- const LLVOAvatar::MatrixPaletteCache& mpc = params.mAvatar->updateSkinInfoMatrixPalette(params.mSkinInfo);
+ const LLVOAvatar::MatrixPaletteCache& mpc = params.mAvatar.get()->updateSkinInfoMatrixPalette(params.mSkinInfo);
U32 count = mpc.mMatrixPalette.size();
if (count == 0)
diff --git a/indra/newview/llspatialpartition.h b/indra/newview/llspatialpartition.h
index eefb5b0eba..acfcd63686 100644
--- a/indra/newview/llspatialpartition.h
+++ b/indra/newview/llspatialpartition.h
@@ -40,6 +40,8 @@
#include "llface.h"
#include "llviewercamera.h"
#include "llvector4a.h"
+#include "llvoavatar.h"
+
#include <queue>
#include <unordered_map>
@@ -125,7 +127,7 @@ public:
F32 mAlphaMaskCutoff;
U8 mDiffuseAlphaMode;
bool mSelected;
- LLVOAvatar* mAvatar = nullptr;
+ LLPointer<LLVOAvatar> mAvatar = nullptr;
LLMeshSkinInfo* mSkinInfo = nullptr;