summaryrefslogtreecommitdiff
path: root/main/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'main/main.cpp')
-rw-r--r--main/main.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/main/main.cpp b/main/main.cpp
index fe0f2693e4..676fa7b836 100644
--- a/main/main.cpp
+++ b/main/main.cpp
@@ -2848,9 +2848,8 @@ void Main::cleanup(bool p_force) {
if (OS::get_singleton()->is_restart_on_exit_set()) {
//attempt to restart with arguments
- String exec = OS::get_singleton()->get_executable_path();
List<String> args = OS::get_singleton()->get_restart_on_exit_arguments();
- OS::get_singleton()->create_process(exec, args);
+ OS::get_singleton()->create_instance(args);
OS::get_singleton()->set_restart_on_exit(false, List<String>()); //clear list (uses memory)
}