[Bf-blender-cvs] [d269fb1d72f] master: Fix assert failures in the dependency graph
Sergey Sharybin
noreply at git.blender.org
Wed Aug 3 09:32:11 CEST 2022
Commit: d269fb1d72f35e3c1cfb99c921d083052b8eb15a
Author: Sergey Sharybin
Date: Wed Aug 3 09:31:05 2022 +0200
Branches: master
https://developer.blender.org/rBd269fb1d72f35e3c1cfb99c921d083052b8eb15a
Fix assert failures in the dependency graph
Happens after recent changes in the area.
The asserts were a bit too strict and were against the way how the
ID_RECALC_ALL is handled. So remove them with explanation why things
needs to be silent.
===================================================================
M source/blender/depsgraph/intern/depsgraph_tag.cc
===================================================================
diff --git a/source/blender/depsgraph/intern/depsgraph_tag.cc b/source/blender/depsgraph/intern/depsgraph_tag.cc
index d95e871d6c7..c508bee3218 100644
--- a/source/blender/depsgraph/intern/depsgraph_tag.cc
+++ b/source/blender/depsgraph/intern/depsgraph_tag.cc
@@ -227,7 +227,9 @@ void depsgraph_tag_to_component_opcode(const ID *id,
case ID_RECALC_PROVISION_29:
case ID_RECALC_PROVISION_30:
case ID_RECALC_PROVISION_31:
- BLI_assert_msg(0, "Should not happen");
+ /* Silently ignore.
+ * The bits might be passed here from ID_RECALC_ALL. This is not a codmistake, but just the
+ * way how the recalc flags are handled. */
break;
}
}
@@ -757,7 +759,10 @@ const char *DEG_update_tag_as_string(IDRecalcFlag flag)
case ID_RECALC_PROVISION_29:
case ID_RECALC_PROVISION_30:
case ID_RECALC_PROVISION_31:
- BLI_assert_msg(0, "Should not happen");
+ /* Silently return nullptr, indicating that there is no string representation.
+ *
+ * This is needed due to the way how logging for ID_RECALC_ALL works: it iterates over all
+ * bits and converts then to string. */
return nullptr;
}
return nullptr;
More information about the Bf-blender-cvs
mailing list