diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-08-05 22:12:34 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-08-05 22:12:34 +0400 |
commit | 5c7217da721833233241357b22fd3013056b1564 (patch) | |
tree | 8d6b76a788f6b484e6412382567833275e25096f /source/blender | |
parent | 887d517e3b745945d3c8f7e2dc6e1d791067d1e8 (diff) |
fix for crash when mask editing if there is an active point but no active spline.
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/editors/mask/mask_add.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/editors/mask/mask_add.c b/source/blender/editors/mask/mask_add.c index 856db013872..e20a7b51d13 100644 --- a/source/blender/editors/mask/mask_add.c +++ b/source/blender/editors/mask/mask_add.c @@ -321,6 +321,7 @@ static void finSelectedSplinePoint(MaskLayer *masklay, MaskSpline **spline, Mask *point = NULL; if (check_active) { + /* TODO, having an active point but no active spline is possible, why? */ if (masklay->act_spline && masklay->act_point && MASKPOINT_ISSEL_ANY(masklay->act_point)) { *spline = masklay->act_spline; *point = masklay->act_point; @@ -562,7 +563,8 @@ static int add_vertex_exec(bContext *C, wmOperator *op) RNA_float_get_array(op->ptr, "location", co); - if (masklay && masklay->act_point && MASKPOINT_ISSEL_ANY(masklay->act_point)) { + /* TODO, having an active point but no active spline is possible, why? */ + if (masklay && masklay->act_spline && masklay->act_point && MASKPOINT_ISSEL_ANY(masklay->act_point)) { /* cheap trick - double click for cyclic */ MaskSpline *spline = masklay->act_spline; |