Fixes a bug in OsdUtilVertexSplit that occurs when getting the address of the end of a std::vector.

This commit is contained in:
Nathan Litke 2014-08-05 18:11:57 -07:00
parent df719eb9ed
commit 22d4939563

View File

@ -94,9 +94,9 @@ OsdUtilVertexSplit<T>::OsdUtilVertexSplit(FarMesh<T> * mesh)
++vertexRange.first, ++j)
{
int fvar = vertexRange.first->second;
if (std::equal(&fvarDataTable[i * fvarWidth],
&fvarDataTable[(i + 1) * fvarWidth],
&fvarDataTable[fvar * fvarWidth]))
const float* fvarData = &fvarDataTable[fvar * fvarWidth];
if (std::equal(fvarData, fvarData + fvarWidth,
&fvarDataTable[i * fvarWidth]))
{
splitTable[i] = j;
goto split_vertex;