From 5d69958442216b926b7d64f259099cd00beea376 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Thu, 15 Sep 2022 17:10:39 +1000 Subject: Correct over allocation in 0e172e9732a1cab2aba324ce10ce304df7b69338 --- source/blender/modifiers/intern/MOD_correctivesmooth.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/blender/modifiers/intern/MOD_correctivesmooth.c b/source/blender/modifiers/intern/MOD_correctivesmooth.c index 5e46e98263c..bed88272ee6 100644 --- a/source/blender/modifiers/intern/MOD_correctivesmooth.c +++ b/source/blender/modifiers/intern/MOD_correctivesmooth.c @@ -696,7 +696,7 @@ static void correctivesmooth_modifier_do(ModifierData *md, tangent_spaces = MEM_malloc_arrayN(loops_num, sizeof(float[3][3]), __func__); tangent_weights = MEM_malloc_arrayN(loops_num, sizeof(float), __func__); - tangent_weights_per_vertex = MEM_malloc_arrayN(loops_num, sizeof(float), __func__); + tangent_weights_per_vertex = MEM_malloc_arrayN(verts_num, sizeof(float), __func__); calc_tangent_spaces( mesh, vertexCos, tangent_spaces, tangent_weights, tangent_weights_per_vertex); -- cgit v1.2.3