diff options
author | Jacques Lucke <jacques@blender.org> | 2021-05-26 13:24:56 +0300 |
---|---|---|
committer | Jacques Lucke <jacques@blender.org> | 2021-05-26 13:25:48 +0300 |
commit | afec66c024dc2b75447537d45406c06342ec201e (patch) | |
tree | 5e2d614542b832e4a3c062b4a373450d49d05a8c /source/blender | |
parent | 12a06292af8678c2371b36369a96c088f438c9dd (diff) |
Fix T88588: crash when muting node with multi input socket
The bug existed before the new evaluator already, but the new evaluator
is more sensitive to this kind of error.
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/nodes/intern/node_tree_ref.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/nodes/intern/node_tree_ref.cc b/source/blender/nodes/intern/node_tree_ref.cc index 5c0bc0b5ebc..8699736e543 100644 --- a/source/blender/nodes/intern/node_tree_ref.cc +++ b/source/blender/nodes/intern/node_tree_ref.cc @@ -297,6 +297,12 @@ void OutputSocketRef::foreach_logical_target( skipped_fn.call_safe(target); for (const InternalLinkRef *internal_link : target_node.internal_links()) { if (&internal_link->from() == &target) { + /* The internal link only forwards the first incoming link. */ + if (target.is_multi_input_socket()) { + if (target.directly_linked_links()[0] != link) { + continue; + } + } const OutputSocketRef &mute_output = internal_link->to(); skipped_fn.call_safe(target); skipped_fn.call_safe(mute_output); |