Merge pull request #7672 from Hinsbart/drag_crash
SceneTreeDock: Fix crash when dragging invalid nodes.
This commit is contained in:
commit
e59e6c69c4
1 changed files with 3 additions and 1 deletions
|
|
@ -1761,7 +1761,9 @@ void SceneTreeDock::_nodes_dragged(Array p_nodes,NodePath p_to,int p_type) {
|
|||
|
||||
for(int i=0;i<p_nodes.size();i++) {
|
||||
Node *n=get_node((p_nodes[i]));
|
||||
nodes.push_back(n);
|
||||
if (n) {
|
||||
nodes.push_back(n);
|
||||
}
|
||||
}
|
||||
|
||||
if (nodes.size()==0)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue