From 2bd2a2ac0334e428b3b5e8340737d0992a2c3d3a Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Mon, 30 Apr 2018 17:31:59 +0200 Subject: Depsgraph: Extra sanity checks for copy-on-write tagging --- source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc | 2 ++ 1 file changed, 2 insertions(+) (limited to 'source/blender/depsgraph/intern') diff --git a/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc b/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc index 3f80bf00be2..cb03c0dc92c 100644 --- a/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc +++ b/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc @@ -800,6 +800,8 @@ bool deg_validate_copy_on_write_datablock(ID *id_cow) void deg_tag_copy_on_write_id(ID *id_cow, const ID *id_orig) { + BLI_assert(id_cow != id_orig); + BLI_assert((id_orig->tag & LIB_TAG_COPY_ON_WRITE) == 0); id_cow->tag |= LIB_TAG_COPY_ON_WRITE; id_cow->orig_id = (ID *)id_orig; } -- cgit v1.2.3