diff options
Diffstat (limited to 'source/blender/modifiers/intern/MOD_laplaciansmooth.c')
-rw-r--r-- | source/blender/modifiers/intern/MOD_laplaciansmooth.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source/blender/modifiers/intern/MOD_laplaciansmooth.c b/source/blender/modifiers/intern/MOD_laplaciansmooth.c index 66c31b60bbd..1acec1d8b7a 100644 --- a/source/blender/modifiers/intern/MOD_laplaciansmooth.c +++ b/source/blender/modifiers/intern/MOD_laplaciansmooth.c @@ -512,8 +512,9 @@ static void deformVerts( laplaciansmoothModifier_do((LaplacianSmoothModifierData *)md, ctx->object, mesh_src, vertexCos, numVerts); - if (mesh_src != mesh) + if (!ELEM(mesh_src, NULL, mesh)) { BKE_id_free(NULL, mesh_src); + } } static void deformVertsEM( @@ -530,8 +531,9 @@ static void deformVertsEM( laplaciansmoothModifier_do((LaplacianSmoothModifierData *)md, ctx->object, mesh_src, vertexCos, numVerts); - if (mesh_src != mesh) + if (!ELEM(mesh_src, NULL, mesh)) { BKE_id_free(NULL, mesh_src); + } } |