Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2012-02-22 17:15:29 +0400
committerSergey Sharybin <sergey.vfx@gmail.com>2012-02-22 17:15:29 +0400
commitf5f529e74091b2c8d383504db4a2fea2c0279959 (patch)
tree71137e94952c1614bcb1fa4f5749b960e36260c0 /source/blender/modifiers/intern
parent4ed01fe734e513e6aec6f96140203ff7d4d61cac (diff)
Fix freeing of NULL pointer in array modifier.
Diffstat (limited to 'source/blender/modifiers/intern')
-rw-r--r--source/blender/modifiers/intern/MOD_mirror.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/source/blender/modifiers/intern/MOD_mirror.c b/source/blender/modifiers/intern/MOD_mirror.c
index 67e723eb1f9..6552ff38645 100644
--- a/source/blender/modifiers/intern/MOD_mirror.c
+++ b/source/blender/modifiers/intern/MOD_mirror.c
@@ -271,11 +271,13 @@ static DerivedMesh *doMirrorOnAxis(MirrorModifierData *mmd,
flip_map= defgroup_flip_map(ob, &flip_map_len, FALSE);
- for (i = maxVerts; i-- > 0; dvert++) {
- defvert_flip(dvert, flip_map, flip_map_len);
- }
+ if (flip_map) {
+ for (i = maxVerts; i-- > 0; dvert++) {
+ defvert_flip(dvert, flip_map, flip_map_len);
+ }
- MEM_freeN(flip_map);
+ MEM_freeN(flip_map);
+ }
}
if (do_vtargetmap) {