diff options
author | Nyx (Neal Orman) <nyx@lindenlab.com> | 2010-09-22 18:09:17 -0400 |
---|---|---|
committer | Nyx (Neal Orman) <nyx@lindenlab.com> | 2010-09-22 18:09:17 -0400 |
commit | 9961df7c19ed11566b2153df18773f86032f185c (patch) | |
tree | 56be5d334ec74f1434d6994c11517b99388a8e18 | |
parent | d2f1f42af257575114c2069562534b88bec0de5d (diff) |
SH-188 FIX crash in llvoavatar.cpp
We were using a NULL pointer after checking it. Did some logic juggling to
ensure that we only use the pointer if it is non-null
Code reviewed by Seraph
-rw-r--r-- | indra/newview/llvoavatar.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index 46d8f65d23..c31714de5a 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -6089,9 +6089,9 @@ void LLVOAvatar::updateMeshTextures() // use the last-known good baked texture until it finish the first // render of the new layerset. - const BOOL layerset_invalid = !mBakedTextureDatas[i].mTexLayerSet - || !mBakedTextureDatas[i].mTexLayerSet->getComposite()->isInitialized() - || !mBakedTextureDatas[i].mTexLayerSet->isLocalTextureDataAvailable(); + const BOOL layerset_invalid = mBakedTextureDatas[i].mTexLayerSet + && ( !mBakedTextureDatas[i].mTexLayerSet->getComposite()->isInitialized() + || !mBakedTextureDatas[i].mTexLayerSet->isLocalTextureDataAvailable() ); use_lkg_baked_layer[i] = (!is_layer_baked[i] && (mBakedTextureDatas[i].mLastTextureIndex != IMG_DEFAULT_AVATAR) |