Skip to content

Commit

Permalink
Merge pull request #1948 from sunnylanwanjun/v2.2.1-release-fix-spine…
Browse files Browse the repository at this point in the history
…-cache-crash

fix spine cache mode render buffer overflow
  • Loading branch information
SantyWang committed Nov 26, 2019
2 parents 5513a8e + a3cc767 commit 36ee9fb
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -424,6 +424,7 @@ namespace spine {

trianglesTwoColor.indexCount = (int)_clipper->getClippedTriangles().size();
ibSize = trianglesTwoColor.indexCount * sizeof(unsigned short);
ib.checkSpace(ibSize, true);
trianglesTwoColor.indices = (unsigned short*)ib.getCurBuffer();
memcpy(trianglesTwoColor.indices, _clipper->getClippedTriangles().buffer(), sizeof(unsigned short) * _clipper->getClippedTriangles().size());

Expand Down

0 comments on commit 36ee9fb

Please sign in to comment.