diff options
author | Nicky <none@none> | 2012-10-22 15:40:18 -0400 |
---|---|---|
committer | Nicky <none@none> | 2012-10-22 15:40:18 -0400 |
commit | fdb0218bfc156842a70661e339ba4592e02dc9c4 (patch) | |
tree | ae71d1b201e71774e1226b120a29b858b7720404 /indra/newview/llface.cpp | |
parent | c8ba971e84b6dba31636dbfba20b2d9ca219f67f (diff) |
Crashfix; Guard against 0 pointer textures.
Diffstat (limited to 'indra/newview/llface.cpp')
-rwxr-xr-x | indra/newview/llface.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/indra/newview/llface.cpp b/indra/newview/llface.cpp index 188f943f13..605cb81c10 100755 --- a/indra/newview/llface.cpp +++ b/indra/newview/llface.cpp @@ -1062,7 +1062,11 @@ bool LLFace::canRenderAsMask() } const LLTextureEntry* te = getTextureEntry(); - + if( !te || !getViewerObject() || !getTexture() ) + { + return false; + } + if ((te->getColor().mV[3] == 1.0f) && // can't treat as mask if we have face alpha (te->getGlow() == 0.f) && // glowing masks are hard to implement - don't mask getTexture()->getIsAlphaMask()) // texture actually qualifies for masking (lazily recalculated but expensive) |