summaryrefslogtreecommitdiff
path: root/indra/newview/llvoavatar.cpp
diff options
context:
space:
mode:
authorNyx (Neal Orman) <nyx@lindenlab.com>2010-09-22 18:10:38 -0400
committerNyx (Neal Orman) <nyx@lindenlab.com>2010-09-22 18:10:38 -0400
commitc395be02b1e8ca6a5d2fed241563bf2fbbc4f3ef (patch)
treed685c73c60fe44d85df4caa081bfe78fb562d9a0 /indra/newview/llvoavatar.cpp
parent90e3d83a5cb35e98a02a3017dd79ebc272bbfe85 (diff)
SH-188 crash in llvoavatar.cpp
We were using a NULL pointer after checking it was null due to a logic error. Re-shuffled the logic to ensure we would only dereference pointer after it was known to be non-null Code reviewed by Seraph
Diffstat (limited to 'indra/newview/llvoavatar.cpp')
-rwxr-xr-xindra/newview/llvoavatar.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp
index a6b3c436f4..54400c184b 100755
--- a/indra/newview/llvoavatar.cpp
+++ b/indra/newview/llvoavatar.cpp
@@ -6189,9 +6189,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)