Skip to content

Commit 3ea8699

Browse files
committed
#4128 Crash on mInvBindMatrix
1 parent 946169a commit 3ea8699

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

indra/newview/llskinningutil.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,12 @@ void LLSkinningUtil::initSkinningMatrixPalette(
135135

136136
initJointNums(const_cast<LLMeshSkinInfo*>(skin), avatar);
137137

138+
if (skin->mInvBindMatrix.size() < count )
139+
{
140+
// faulty model? mInvBindMatrix.size() should have matched mJointNames.size()
141+
return;
142+
}
143+
138144
LLMatrix4a world[LL_CHARACTER_MAX_ANIMATED_JOINTS];
139145

140146
for (S32 j = 0; j < count; ++j)

0 commit comments

Comments
 (0)