Fix T82149: Blender crash when using collection user_id remapping (python).

Not sure why Collection was the only ID for which depsgraph building did
not check for potential recursion?

Reviewed By: sergey

Maniphest Tasks: T82149

Differential Revision: https://developer.blender.org/D9365
This commit is contained in:
Bastien Montagne 2020-10-28 11:04:49 +01:00 committed by Bastien Montagne
parent a8ca79cbe6
commit 0d772221c6
Notes: blender-bot 2023-02-14 08:10:10 +01:00
Referenced by issue #82149, Blender crash when using collection user_id remapping (python)
1 changed files with 1 additions and 1 deletions

View File

@ -591,13 +591,13 @@ void DepsgraphRelationBuilder::build_collection(LayerCollection *from_layer_coll
* recurses into all the nested objects and collections. */
return;
}
build_idproperties(collection->id.properties);
const bool group_done = built_map_.checkIsBuiltAndTag(collection);
OperationKey object_transform_final_key(object != nullptr ? &object->id : nullptr,
NodeType::TRANSFORM,
OperationCode::TRANSFORM_FINAL);
ComponentKey duplicator_key(object != nullptr ? &object->id : nullptr, NodeType::DUPLI);
if (!group_done) {
build_idproperties(collection->id.properties);
LISTBASE_FOREACH (CollectionObject *, cob, &collection->gobject) {
build_object(cob->ob);
}