diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-07-25 06:23:05 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-07-25 06:23:05 +0300 |
commit | 2e92791074deb9cc5f0e96d7621b71cfd79cac1c (patch) | |
tree | 295259dcd8b6ce0b2e839ced63a4356a1427b236 /source/blender/blenkernel/intern | |
parent | 419f137c642bdc159d2416a4596d1cf9cbe16595 (diff) |
Fix crash validating mesh polygons with invalid loop-start
Add check for negative loop-start,
fixes crash validating test file from T67605.
Diffstat (limited to 'source/blender/blenkernel/intern')
-rw-r--r-- | source/blender/blenkernel/intern/mesh_validate.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/mesh_validate.c b/source/blender/blenkernel/intern/mesh_validate.c index dac12233539..c8e75532075 100644 --- a/source/blender/blenkernel/intern/mesh_validate.c +++ b/source/blender/blenkernel/intern/mesh_validate.c @@ -1200,7 +1200,7 @@ void BKE_mesh_strip_loose_polysloops(Mesh *me) int i = p->loopstart; int stop = i + p->totloop; - if (stop > me->totloop || stop < i) { + if (stop > me->totloop || stop < i || p->loopstart < 0) { invalid = true; } else { |