MTGS: Prevent the emulator from crashing if GS fails to init

This commit is contained in:
TellowKrinkle 2022-04-24 23:09:34 -05:00 committed by tellowkrinkle
parent 1ad6532f1a
commit cc5142000b
1 changed files with 2 additions and 0 deletions

View File

@ -859,6 +859,8 @@ bool SysMtgsThread::WaitForOpen()
}
RethrowException();
if (!m_Opened) // EE thread will continue running and explode everything if we don't throw an exception
throw Exception::RuntimeError(std::runtime_error("GS failed to open."));
return m_Opened;
#else
if (!m_sem_OpenDone.Wait(wxTimeSpan(0, 0, 12, 0)) || !m_Opened)