summaryrefslogtreecommitdiff
path: root/editor/script_editor_debugger.cpp
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2018-02-21 13:31:20 +0100
committerGitHub <noreply@github.com>2018-02-21 13:31:20 +0100
commit1c77fdcc8516cf2f0c5083d4840a684b9ad90958 (patch)
tree1a7f948adc49a61e58e74a86f33411fb039c9172 /editor/script_editor_debugger.cpp
parent35053e57abaca188a080106df5559e611251d1a5 (diff)
parentcfde7374785d2e4033ebcee0459836c648439eb6 (diff)
Merge pull request #16882 from GodotExplorer/debugger-improvement-1
Small improvements for the debugger
Diffstat (limited to 'editor/script_editor_debugger.cpp')
-rw-r--r--editor/script_editor_debugger.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/editor/script_editor_debugger.cpp b/editor/script_editor_debugger.cpp
index 4fc73b2a8e..36df5f6ccc 100644
--- a/editor/script_editor_debugger.cpp
+++ b/editor/script_editor_debugger.cpp
@@ -1285,14 +1285,14 @@ void ScriptEditorDebugger::_stack_dump_frame_selected() {
emit_signal("goto_script_line", stack_script, int(d["line"]) - 1);
stack_script.unref();
- ERR_FAIL_COND(connection.is_null());
- ERR_FAIL_COND(!connection->is_connected_to_host());
- ///
-
- Array msg;
- msg.push_back("get_stack_frame_vars");
- msg.push_back(d["frame"]);
- ppeer->put_var(msg);
+ if (connection.is_valid() && connection->is_connected_to_host()) {
+ Array msg;
+ msg.push_back("get_stack_frame_vars");
+ msg.push_back(d["frame"]);
+ ppeer->put_var(msg);
+ } else {
+ inspector->edit(NULL);
+ }
}
void ScriptEditorDebugger::_output_clear() {