mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-28 19:58:53 +00: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:
commit
b10808d815
5 changed files with 83 additions and 25 deletions
|
@ -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);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue