Fix T58117: Crash with keyframing
authorSergey Sharybin <sergey.vfx@gmail.com>
Tue, 4 Dec 2018 10:28:23 +0000 (11:28 +0100)
committerSergey Sharybin <sergey.vfx@gmail.com>
Tue, 4 Dec 2018 10:28:54 +0000 (11:28 +0100)
source/blender/editors/animation/keyframing.c

index 4bf6c43e34816cd1532c063c5657f2d0c8d9f2ec..9faa7a8e8cde0aaae0c2490163ebe51870f738c5 100644 (file)
@@ -1392,7 +1392,12 @@ static short clear_keyframe(Main *bmain, ReportList *reports, ID *id, bAction *a
                /* return success */
                ret++;
        }
-
+       /* In the case last f-curve wes removed need to inform dependency graph
+        * about relations update, since it needs to get rid of animation operation
+        * for this datablock. */
+       if (adt->action == NULL) {
+               DEG_relations_tag_update(bmain);
+       }
        /* return success/failure */
        return ret;
 }