Make GDB server able to be attached when the emulator starts

This commit is contained in:
Jeffrey Pfau 2014-02-03 03:42:29 -08:00
parent d16737ccf2
commit 8c53fbeb4f
1 changed files with 1 additions and 1 deletions

View File

@ -68,7 +68,7 @@ void GameController::setDebugger(ARMDebugger* debugger) {
GBADetachDebugger(m_threadContext.gba); GBADetachDebugger(m_threadContext.gba);
} }
m_threadContext.debugger = debugger; m_threadContext.debugger = debugger;
if (m_threadContext.debugger) { if (m_threadContext.debugger && GBAThreadHasStarted(&m_threadContext)) {
GBAAttachDebugger(m_threadContext.gba, m_threadContext.debugger); GBAAttachDebugger(m_threadContext.gba, m_threadContext.debugger);
} }
setPaused(wasPaused); setPaused(wasPaused);