From deef878f6fbac07cdfcba8d73e45f7aad71d3a12 Mon Sep 17 00:00:00 2001 From: Marcelo Fernandez Date: Tue, 19 Jun 2018 22:47:34 -0300 Subject: [PATCH] Add missing NULL checks for add_child_below_node (cherry picked from commit 8c1c7ff1314bad018162c14aaff9d0124aed070e) --- scene/main/node.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scene/main/node.cpp b/scene/main/node.cpp index d5a92b9314a..c05d5af9557 100644 --- a/scene/main/node.cpp +++ b/scene/main/node.cpp @@ -1357,6 +1357,10 @@ void Node::add_child(Node *p_child, bool p_legible_unique_name) { } void Node::add_child_below_node(Node *p_node, Node *p_child, bool p_legible_unique_name) { + + ERR_FAIL_NULL(p_node); + ERR_FAIL_NULL(p_child); + add_child(p_child, p_legible_unique_name); if (is_a_parent_of(p_node)) {