diff options
Diffstat (limited to 'source/blender/makesrna/intern/rna_pose.c')
-rw-r--r-- | source/blender/makesrna/intern/rna_pose.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/source/blender/makesrna/intern/rna_pose.c b/source/blender/makesrna/intern/rna_pose.c index 0f8f8d39c41..8c4b7dd52d9 100644 --- a/source/blender/makesrna/intern/rna_pose.c +++ b/source/blender/makesrna/intern/rna_pose.c @@ -648,7 +648,7 @@ bool rna_PoseChannel_constraints_override_apply(Main *UNUSED(bmain), /* Remember that insertion operations are defined and stored in correct order, which means that * even if we insert several items in a row, we always insert first one, then second one, etc. - * So we should always find 'anchor' constraint in both _src *and* _dst> */ + * So we should always find 'anchor' constraint in both _src *and* _dst */ bConstraint *con_anchor = NULL; if (opop->subitem_local_name && opop->subitem_local_name[0]) { con_anchor = BLI_findstring( @@ -669,7 +669,11 @@ bool rna_PoseChannel_constraints_override_apply(Main *UNUSED(bmain), } con_src = con_src ? con_src->next : pchan_src->constraints.first; - BLI_assert(con_src != NULL); + if (con_src == NULL) { + printf("%s: Could not find constraint to insert, doing nothing...\n", __func__); + BLI_assert(0); + return false; + } bConstraint *con_dst = BKE_constraint_duplicate_ex(con_src, 0, true); |