diff --git a/src/plugins/debugger/gdb/coregdbadapter.cpp b/src/plugins/debugger/gdb/coregdbadapter.cpp index 0c2356ec58139b6c4011d984ce13d010dd405755..5fa80055c5e98ad4787aa98ffde27fc217e558db 100644 --- a/src/plugins/debugger/gdb/coregdbadapter.cpp +++ b/src/plugins/debugger/gdb/coregdbadapter.cpp @@ -149,6 +149,9 @@ void CoreGdbAdapter::handleTargetCore1(const GdbResponse &response) emit inferiorStartFailed(tr("No binary found.")); } else { m_executable = console.data().mid(pos1 + 1, pos2 - pos1 - 1); + // Strip off command line arguments. FIXME: make robust. + if (m_executable.contains(' ')) + m_executable = m_executable.section(' ', 0, 0); QTC_ASSERT(!m_executable.isEmpty(), /**/); // Finish extra round. m_engine->postCommand(_("detach"), CB(handleDetach1)); diff --git a/src/plugins/debugger/gdb/gdbengine.cpp b/src/plugins/debugger/gdb/gdbengine.cpp index 8e3cf81e36f89e6135ab445600c386d97302d4ae..dfd9e954104cab9d559db95bcf51cdde0b1b86a4 100644 --- a/src/plugins/debugger/gdb/gdbengine.cpp +++ b/src/plugins/debugger/gdb/gdbengine.cpp @@ -2368,7 +2368,7 @@ void GdbEngine::handleStackListFrames(const GdbResponse &response) void GdbEngine::activateFrame(int frameIndex) { m_manager->resetLocation(); - if (state() != InferiorStopped) + if (state() != InferiorStopped && state() != InferiorUnrunnable) return; StackHandler *stackHandler = manager()->stackHandler();