Browse Source

fix crash when using one-click deploy

LuoZhihao 8 months ago
parent
commit
8f03548680
1 changed files with 3 additions and 0 deletions
  1. 3 0
      editor/editor_run.cpp

+ 3 - 0
editor/editor_run.cpp

@@ -285,6 +285,9 @@ void EditorRun::stop() {
 }
 
 OS::ProcessID EditorRun::get_current_process() const {
+	if (pids.front() == nullptr) {
+		return 0;
+	}
 	return pids.front()->get();
 }