diff options
author | Callum Prentice <callum@gmail.com> | 2016-12-15 10:58:23 -0800 |
---|---|---|
committer | Callum Prentice <callum@gmail.com> | 2016-12-15 10:58:23 -0800 |
commit | 067468885a189bb26b465dbff2358de81cc6e392 (patch) | |
tree | c6cbf0aed57d806a3a14471387fb107ec0b02d6e /indra | |
parent | bf0a0807de5bbe5c47501e0b79f40d5e89da7811 (diff) |
BUG-41027 (FIX) Changing login location at the login screen crashes the viewer
Diffstat (limited to 'indra')
-rw-r--r-- | indra/llrender/llrender.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/indra/llrender/llrender.cpp b/indra/llrender/llrender.cpp index 0e242a20f6..98d3ab8435 100644 --- a/indra/llrender/llrender.cpp +++ b/indra/llrender/llrender.cpp @@ -2156,9 +2156,12 @@ void LLRender::vertexBatchPreTransformed(LLVector3* verts, LLVector2* uvs, LLCol } } - mVerticesp[mCount] = mVerticesp[mCount-1]; - mTexcoordsp[mCount] = mTexcoordsp[mCount-1]; - mColorsp[mCount] = mColorsp[mCount-1]; + if (mCount > 0) + { + mVerticesp[mCount] = mVerticesp[mCount - 1]; + mTexcoordsp[mCount] = mTexcoordsp[mCount - 1]; + mColorsp[mCount] = mColorsp[mCount - 1]; + } } void LLRender::vertex2i(const GLint& x, const GLint& y) |