diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2019-07-19 22:04:33 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-07-19 22:04:33 +0200 |
commit | 0bf930c1176ed26155aa352b1f937c8ae043272e (patch) | |
tree | a97cdd7fb0ed748ae17afbff2e5f1f25178c64cd | |
parent | c317a3ce16a35b21d85b250a0e810526bb89db38 (diff) | |
parent | ed84c9e506469342bc5d6e03838dce9ea2672437 (diff) |
Merge pull request #30692 from qarmin/null_pointer_to_function
Don't allow to pass to _is_node_locked function NULL pointer
-rw-r--r-- | editor/plugins/spatial_editor_plugin.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/editor/plugins/spatial_editor_plugin.cpp b/editor/plugins/spatial_editor_plugin.cpp index a593a92b97..b475eee920 100644 --- a/editor/plugins/spatial_editor_plugin.cpp +++ b/editor/plugins/spatial_editor_plugin.cpp @@ -514,7 +514,7 @@ void SpatialEditorViewport::_select_region() { for (int i = 0; i < instances.size(); i++) { Spatial *sp = Object::cast_to<Spatial>(ObjectDB::get_instance(instances[i])); - if (!sp && _is_node_locked(sp)) + if (!sp || _is_node_locked(sp)) continue; Node *item = Object::cast_to<Node>(sp); |