Commit: 69aabd33af2bed09e4c73f6a204f05ddd705bd74
Author: Sergey Sharybin
Date: Fri Feb 13 14:15:56 2015 +0500
Branches: depsgraph_refactor
https://developer.blender.org/rB69aabd33af2bed09e4c73f6a204f05ddd705bd74
Depsgraph: Fix crash when trying to tag NULL for recalc
I would say it's better to be avoid to tag NULL for update, but old
depsgraph allowed that and nobody id check for it.
===================================================================
M source/blender/depsgraph/intern/depsgraph_tag.cpp
===================================================================
diff --git a/source/blender/depsgraph/intern/depsgraph_tag.cpp
b/source/blender/depsgraph/intern/depsgraph_tag.cpp
index 245b4fa..44c5615 100644
--- a/source/blender/depsgraph/intern/depsgraph_tag.cpp
+++ b/source/blender/depsgraph/intern/depsgraph_tag.cpp
@@ -136,6 +136,10 @@ void DEG_id_tag_update(ID *id, short flag)
void DEG_id_tag_update_ex(Main *bmain, ID *id, short flag)
{
+ if(id == NULL) {
+ /* Ideally should not happen, but old depsgraph allowed this. */
+ return;
+ }
DEG_DEBUG_PRINTF("%s: id=%s flag=%d\n", __func__, id->name, flag);
lib_id_recalc_tag_flag(bmain, id, flag);
for (Scene *scene = (Scene *)bmain->scene.first;
_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs