Fix relaunch_self on w11

This commit is contained in:
fed 2023-03-01 09:31:28 +01:00
parent 08c8d17044
commit 2f7d03437a

View File

@ -275,8 +275,8 @@ namespace utils::nt
} }
} }
CreateProcessA(self.get_path().generic_string().data(), command_line.data(), nullptr, nullptr, false, NULL, nullptr, current_dir, CreateProcessA(self.get_path().generic_string().data(), command_line.data(), nullptr, nullptr, false,
&startup_info, &process_info); CREATE_NEW_CONSOLE, nullptr, current_dir, &startup_info, &process_info);
if (process_info.hThread && process_info.hThread != INVALID_HANDLE_VALUE) CloseHandle(process_info.hThread); if (process_info.hThread && process_info.hThread != INVALID_HANDLE_VALUE) CloseHandle(process_info.hThread);
if (process_info.hProcess && process_info.hProcess != INVALID_HANDLE_VALUE) CloseHandle(process_info.hProcess); if (process_info.hProcess && process_info.hProcess != INVALID_HANDLE_VALUE) CloseHandle(process_info.hProcess);