[Bf-blender-cvs] [18a91ecee78] master: Fix: Assert failure when joining nodes with frame

Hans Goudey noreply at git.blender.org
Thu Dec 8 22:14:43 CET 2022


Commit: 18a91ecee7827271568a783affa544b69174a4ee
Author: Hans Goudey
Date:   Thu Dec 8 15:12:10 2022 -0600
Branches: master
https://developer.blender.org/rB18a91ecee7827271568a783affa544b69174a4ee

Fix: Assert failure when joining nodes with frame

The node "index in tree" needs to be updated when adding the frame node.

===================================================================

M	source/blender/editors/space_node/node_relationships.cc

===================================================================

diff --git a/source/blender/editors/space_node/node_relationships.cc b/source/blender/editors/space_node/node_relationships.cc
index 93761388f43..f4c9b9d08aa 100644
--- a/source/blender/editors/space_node/node_relationships.cc
+++ b/source/blender/editors/space_node/node_relationships.cc
@@ -1680,6 +1680,8 @@ static int node_join_exec(bContext *C, wmOperator * /*op*/)
   bNode *frame_node = nodeAddStaticNode(C, &ntree, NODE_FRAME);
   nodeSetActive(&ntree, frame_node);
 
+  ntree.ensure_topology_cache();
+
   Array<NodeJoinState> join_states(ntree.all_nodes().size(), NodeJoinState{false, false});
 
   for (bNode *node : ntree.all_nodes()) {



More information about the Bf-blender-cvs mailing list