summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorOz Linden <oz@lindenlab.com>2016-12-16 09:09:48 -0500
committerOz Linden <oz@lindenlab.com>2016-12-16 09:09:48 -0500
commit17ca7fc38d7abebd009396d6a2ad22edc3ed7836 (patch)
tree9f51450de1270900e23fe1712e800caceb0cb52c /indra
parent058ac4ba50acb8f2b1340136a69bfe52ad7be425 (diff)
parentaa5a591aa722c81de2b22d9126afa4a833d0c050 (diff)
merge latest integrations from callum
Diffstat (limited to 'indra')
-rw-r--r--indra/llrender/llrender.cpp9
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)