mirror of
https://github.com/godotengine/godot.git
synced 2026-02-07 11:21:49 +00:00
Merge pull request #115919 from cdemirer/fix-blendtree-use-after-free
Fix use-after-free in Animation Blend Tree
This commit is contained in:
@@ -1590,7 +1590,8 @@ void AnimationNodeBlendTree::rename_node(const StringName &p_name, const StringN
|
||||
|
||||
nodes[p_name].node->disconnect_changed(callable_mp(this, &AnimationNodeBlendTree::_node_changed));
|
||||
|
||||
nodes[p_new_name] = nodes[p_name];
|
||||
const Node temp_copy = nodes[p_name];
|
||||
nodes[p_new_name] = temp_copy; // might realloc
|
||||
nodes.erase(p_name);
|
||||
|
||||
// Rename connections.
|
||||
|
||||
Reference in New Issue
Block a user