mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-09 00:11:24 +12:00
Don't use std::exit during Qt initialization
This commit is contained in:
parent
7ce835e878
commit
2865865382
12 changed files with 62 additions and 22 deletions
|
@ -507,17 +507,28 @@ int main(int argc, char** argv)
|
|||
|
||||
gui_app->SetShowGui(!s_no_gui);
|
||||
gui_app->SetUseCliStyle(use_cli_style);
|
||||
gui_app->Init();
|
||||
|
||||
if (!gui_app->Init())
|
||||
{
|
||||
Emu.Quit(true);
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
else if (auto headless_app = qobject_cast<headless_application*>(app.data()))
|
||||
{
|
||||
s_headless = true;
|
||||
headless_app->Init();
|
||||
|
||||
if (!headless_app->Init())
|
||||
{
|
||||
Emu.Quit(true);
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Should be unreachable
|
||||
report_fatal_error("RPCS3 initialization failed!");
|
||||
return 1;
|
||||
}
|
||||
|
||||
#ifdef _WIN32
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue