diff --git a/src/plugins/debugger/gdb/gdbengine.cpp b/src/plugins/debugger/gdb/gdbengine.cpp index 12fb509fca4baafade2391ab7e0a30b067fc7eff..1fbd98e7798577960798b0345941060a3214422d 100644 --- a/src/plugins/debugger/gdb/gdbengine.cpp +++ b/src/plugins/debugger/gdb/gdbengine.cpp @@ -324,7 +324,6 @@ void GdbEngine::initializeVariables() m_outputCodec = QTextCodec::codecForLocale(); m_pendingRequests = 0; m_continuationAfterDone = 0; - m_waitingForFirstBreakpointToBeHit = false; m_commandsToRunOnTemporaryBreak.clear(); m_cookieForToken.clear(); m_customOutputForToken.clear(); @@ -1122,21 +1121,6 @@ void GdbEngine::handleAsyncOutput(const GdbMi &data) return; } - //MAC: bool isFirstStop = data.findChild("bkptno").data() == "1"; - //!MAC: startSymbolName == data.findChild("frame").findChild("func") - if (m_waitingForFirstBreakpointToBeHit) { - m_waitingForFirstBreakpointToBeHit = false; - - // If the executable dies already that early we might get something - // like >49*stopped,reason="exited",exit-code="0177" - // This is handled now above. - - qq->notifyInferiorStopped(); - handleAqcuiredInferior(); -// FIXME: m_continuationAfterDone = true; - return; - } - if (!m_commandsToRunOnTemporaryBreak.isEmpty()) { QTC_ASSERT(status() == DebuggerInferiorStopRequested, qDebug() << "STATUS:" << status()) @@ -1369,11 +1353,13 @@ void GdbEngine::handleStop2(const GdbMi &data) qq->stackHandler()->setCurrentIndex(0); updateLocals(); // Quick shot - int currentId = data.findChild("thread-id").data().toInt(); - reloadStack(); - if (supportsThreads()) - postCommand(_("-thread-list-ids"), WatchUpdate, CB(handleStackListThreads), currentId); + + if (supportsThreads()) { + int currentId = data.findChild("thread-id").data().toInt(); + postCommand(_("-thread-list-ids"), WatchUpdate, + CB(handleStackListThreads), currentId); + } // // Registers @@ -1616,31 +1602,6 @@ void GdbEngine::continueInferior() } #if 0 -void GdbEngine::handleAttach(const GdbResultRecord &, const QVariant &) -{ - qq->notifyInferiorStopped(); - showStatusMessage(tr("Attached to running process. Stopped.")); - handleAqcuiredInferior(); - - m_manager->resetLocation(); - recheckDebuggingHelperAvailability(); - - // - // Stack - // - qq->stackHandler()->setCurrentIndex(0); - updateLocals(); // Quick shot - - reloadStack(); - if (supportsThreads()) - postCommand(_("-thread-list-ids"), WatchUpdate, CB(handleStackListThreads), 0); - - // - // Registers - // - qq->reloadRegisters(); -} - void GdbEngine::handleSetTargetAsync(const GdbResultRecord &record, const QVariant &) { if (record.resultClass == GdbResultDone) { diff --git a/src/plugins/debugger/gdb/gdbengine.h b/src/plugins/debugger/gdb/gdbengine.h index eb97e06c6a5bfe74386060210a44cdce1b8aa3a2..4ab56fb4e874e3021246e9585c8ca35ae8b3f20c 100644 --- a/src/plugins/debugger/gdb/gdbengine.h +++ b/src/plugins/debugger/gdb/gdbengine.h @@ -251,7 +251,6 @@ private: int terminationIndex(const QByteArray &buffer, int &length); void handleResponse(const QByteArray &buff); void handleStart(const GdbResultRecord &response, const QVariant &); - //void handleAttach(const GdbResultRecord &, const QVariant &); void handleAqcuiredInferior(); void handleAsyncOutput(const GdbMi &data); void handleStop1(const GdbResultRecord &, const QVariant &cookie); @@ -260,7 +259,6 @@ private: void handleResultRecord(const GdbResultRecord &response); void handleFileExecAndSymbols(const GdbResultRecord &response, const QVariant &); void handleExecContinue(const GdbResultRecord &response, const QVariant &); - //void handleExecRun(const GdbResultRecord &response, const QVariant &); void handleExecJumpToLine(const GdbResultRecord &response, const QVariant &); void handleExecRunToFunction(const GdbResultRecord &response, const QVariant &); void handleInfoShared(const GdbResultRecord &response, const QVariant &); @@ -432,7 +430,6 @@ private: Continuation m_continuationAfterDone; void handleInitialBreakpointsSet(); - bool m_waitingForFirstBreakpointToBeHit; bool m_modulesListOutdated; QList<GdbCommand> m_commandsToRunOnTemporaryBreak;