diff options
author | Germano <germano.costa@ig.com.br> | 2018-05-29 21:39:44 +0300 |
---|---|---|
committer | Germano <germano.costa@ig.com.br> | 2018-05-29 21:39:44 +0300 |
commit | 00dc1c08aacf46546883a41068a9e6aad1fe3c04 (patch) | |
tree | b4b2f5c25ca76c9631b07528554875dabccb7eff /source/blender/blenkernel | |
parent | f8908f0d434886dcf16da61bcf6d4bb47d407001 (diff) |
Fix T55223: Crash when changing lattice resolution.
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r-- | source/blender/blenkernel/intern/lattice.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source/blender/blenkernel/intern/lattice.c b/source/blender/blenkernel/intern/lattice.c index 2a60bd94d10..0d4f0f923e4 100644 --- a/source/blender/blenkernel/intern/lattice.c +++ b/source/blender/blenkernel/intern/lattice.c @@ -211,8 +211,10 @@ void BKE_lattice_resize(Lattice *lt, int uNew, int vNew, int wNew, Object *ltOb) /* works best if we force to linear type (endpoints match) */ lt->typeu = lt->typev = lt->typew = KEY_LINEAR; - /* prevent using deformed locations */ - BKE_displist_free(<Ob->curve_cache->disp); + if (ltOb->curve_cache) { + /* prevent using deformed locations */ + BKE_displist_free(<Ob->curve_cache->disp) + } copy_m4_m4(mat, ltOb->obmat); unit_m4(ltOb->obmat); |