mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-02-14 09:40:52 +00:00
DolphinQt: Only update call stack if paused
This avoids a pseudo infinite loop where CodeWidget::UpdateCallstack would lock the CPU in order to read the call stack, causing the CPU to call Host_UpdateDisasmDialog because it's transitioning from running to pausing, causing Host::UpdateDisasmDialog to be emitted, causing CodeWidget::Update to be called, once again causing CodeWidget::UpdateCallstack to be called, repeating the cycle. Dolphin didn't go completely unresponsive during this, because Host_UpdateDisasmDialog schedules the emitting of Host::UpdateDisasmDialog to happen on another thread without blocking, but it was stopping certain operations like exiting emulation from working.
This commit is contained in:
parent
7cecb28bdf
commit
6f0266e8de
@ -322,11 +322,11 @@ void CodeWidget::Update()
|
|||||||
|
|
||||||
void CodeWidget::UpdateCallstack()
|
void CodeWidget::UpdateCallstack()
|
||||||
{
|
{
|
||||||
if (Core::GetState() == Core::State::Starting)
|
|
||||||
return;
|
|
||||||
|
|
||||||
m_callstack_list->clear();
|
m_callstack_list->clear();
|
||||||
|
|
||||||
|
if (Core::GetState() != Core::State::Paused)
|
||||||
|
return;
|
||||||
|
|
||||||
std::vector<Dolphin_Debugger::CallstackEntry> stack;
|
std::vector<Dolphin_Debugger::CallstackEntry> stack;
|
||||||
|
|
||||||
const bool success = [&stack] {
|
const bool success = [&stack] {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user