summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorXiaohong Bao <bao@lindenlab.com>2009-12-10 16:56:09 -0700
committerXiaohong Bao <bao@lindenlab.com>2009-12-10 16:56:09 -0700
commit558190f50c1a90b0d11b68b24f60bce482c6a6ec (patch)
tree424c98cec3f0e91b74fd31ec13662b3627012c6f /indra/newview
parent9b4d09471cca6922257a27ba9cb70498ab81fd94 (diff)
fix for DEV-43870: EXT-3137: Crash when add quicktime media to multiple faces.
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/llviewertexture.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/indra/newview/llviewertexture.cpp b/indra/newview/llviewertexture.cpp
index 0d29efaedf..a5a40e9c2c 100644
--- a/indra/newview/llviewertexture.cpp
+++ b/indra/newview/llviewertexture.cpp
@@ -2879,7 +2879,8 @@ BOOL LLViewerMediaTexture::findFaces()
}
S32 face_id = -1 ;
- while((face_id = obj->getFaceIndexWithMediaImpl(mMediaImplp, face_id)) > -1)
+ S32 num_faces = obj->mDrawable->getNumFaces() ;
+ while((face_id = obj->getFaceIndexWithMediaImpl(mMediaImplp, face_id)) > -1 && face_id < num_faces)
{
LLFace* facep = obj->mDrawable->getFace(face_id) ;
if(facep)