mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-21 05:09:34 -06:00
Merge pull request #8763 from JosJuice/panic-alert-deadlock-gpu
DolphinQt: Fix the panic alert deadlock, dual core edition
This commit is contained in:
@ -421,10 +421,10 @@ bool RenderWidget::event(QEvent* event)
|
||||
|
||||
if (Config::Get(Config::MAIN_PAUSE_ON_FOCUS_LOST) && Core::GetState() == Core::State::Running)
|
||||
{
|
||||
// If we are declared as the CPU thread, it means that the real CPU thread is waiting
|
||||
// for us to finish showing a panic alert (with that panic alert likely being the cause
|
||||
// of this event), so trying to pause the real CPU thread would cause a deadlock
|
||||
if (!Core::IsCPUThread())
|
||||
// If we are declared as the CPU or GPU thread, it means that the real CPU or GPU thread
|
||||
// is waiting for us to finish showing a panic alert (with that panic alert likely being
|
||||
// the cause of this event), so trying to pause the core would cause a deadlock
|
||||
if (!Core::IsCPUThread() && !Core::IsGPUThread())
|
||||
Core::SetState(Core::State::Paused);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user