forked from qt-creator/qt-creator
debugger: refactoring
rename GdbResultRecord into GdbResponse merge cookie QVariant into GdbResponse move debugMessage convienience function from individual adapters to base
This commit is contained in:
@@ -118,6 +118,8 @@ protected:
|
||||
void setState(GdbAdapterState state);
|
||||
const DebuggerStartParameters &startParameters() const
|
||||
{ return m_engine->startParameters(); }
|
||||
void debugMessage(const QString &msg) const
|
||||
{ m_engine->debugMessage(msg); }
|
||||
|
||||
GdbEngine * const m_engine;
|
||||
GdbAdapterState m_state;
|
||||
|
||||
@@ -102,16 +102,15 @@ void AttachGdbAdapter::handleGdbStarted()
|
||||
|
||||
void AttachGdbAdapter::prepareInferior()
|
||||
{
|
||||
const qint64 pid = startParameters().attachPID;
|
||||
QTC_ASSERT(state() == AdapterStarted, qDebug() << state());
|
||||
setState(InferiorPreparing);
|
||||
qDebug() << "USING " << pid;
|
||||
const qint64 pid = startParameters().attachPID;
|
||||
m_engine->postCommand(_("attach %1").arg(pid), CB(handleAttach));
|
||||
// Task 254674 does not want to remove them
|
||||
//qq->breakHandler()->removeAllBreakpoints();
|
||||
}
|
||||
|
||||
void AttachGdbAdapter::handleAttach(const GdbResultRecord &response, const QVariant &)
|
||||
void AttachGdbAdapter::handleAttach(const GdbResponse &response)
|
||||
{
|
||||
QTC_ASSERT(state() == InferiorPreparing, qDebug() << state());
|
||||
if (response.resultClass == GdbResultDone) {
|
||||
@@ -131,7 +130,7 @@ void AttachGdbAdapter::startInferior()
|
||||
m_engine->postCommand(_("-exec-continue"), CB(handleContinue));
|
||||
}
|
||||
|
||||
void AttachGdbAdapter::handleContinue(const GdbResultRecord &response, const QVariant &)
|
||||
void AttachGdbAdapter::handleContinue(const GdbResponse &response)
|
||||
{
|
||||
QTC_ASSERT(state() == InferiorStarting, qDebug() << state());
|
||||
if (response.resultClass == GdbResultRunning) {
|
||||
@@ -169,7 +168,7 @@ void AttachGdbAdapter::shutdown()
|
||||
QTC_ASSERT(state() == AdapterNotRunning, qDebug() << state());
|
||||
}
|
||||
|
||||
void AttachGdbAdapter::handleDetach(const GdbResultRecord &response, const QVariant &)
|
||||
void AttachGdbAdapter::handleDetach(const GdbResponse &response)
|
||||
{
|
||||
if (response.resultClass == GdbResultDone) {
|
||||
setState(InferiorShutDown);
|
||||
@@ -183,7 +182,7 @@ void AttachGdbAdapter::handleDetach(const GdbResultRecord &response, const QVari
|
||||
}
|
||||
}
|
||||
|
||||
void AttachGdbAdapter::handleExit(const GdbResultRecord &response, const QVariant &)
|
||||
void AttachGdbAdapter::handleExit(const GdbResponse &response)
|
||||
{
|
||||
if (response.resultClass == GdbResultDone) {
|
||||
// don't set state here, this will be handled in handleGdbFinished()
|
||||
|
||||
@@ -67,12 +67,11 @@ private:
|
||||
void interruptInferior();
|
||||
void shutdown();
|
||||
|
||||
void handleAttach(const GdbResultRecord &, const QVariant &);
|
||||
void handleContinue(const GdbResultRecord &, const QVariant &);
|
||||
void handleDetach(const GdbResultRecord &, const QVariant &);
|
||||
void handleExit(const GdbResultRecord &, const QVariant &);
|
||||
void handleAttach(const GdbResponse &response);
|
||||
void handleContinue(const GdbResponse &response);
|
||||
void handleDetach(const GdbResponse &response);
|
||||
void handleExit(const GdbResponse &response);
|
||||
|
||||
void debugMessage(const QString &msg) { m_engine->debugMessage(msg); }
|
||||
Q_SLOT void handleGdbFinished(int, QProcess::ExitStatus);
|
||||
Q_SLOT void handleGdbStarted();
|
||||
|
||||
|
||||
@@ -112,7 +112,7 @@ void CoreGdbAdapter::prepareInferior()
|
||||
CB(handleFileExecAndSymbols));
|
||||
}
|
||||
|
||||
void CoreGdbAdapter::handleFileExecAndSymbols(const GdbResultRecord &response, const QVariant &)
|
||||
void CoreGdbAdapter::handleFileExecAndSymbols(const GdbResponse &response)
|
||||
{
|
||||
QTC_ASSERT(state() == InferiorPreparing, qDebug() << state());
|
||||
if (response.resultClass == GdbResultDone) {
|
||||
@@ -139,7 +139,7 @@ void CoreGdbAdapter::startInferior()
|
||||
m_engine->postCommand(_("target core ") + coreName, CB(handleTargetCore));
|
||||
}
|
||||
|
||||
void CoreGdbAdapter::handleTargetCore(const GdbResultRecord &response, const QVariant &)
|
||||
void CoreGdbAdapter::handleTargetCore(const GdbResponse &response)
|
||||
{
|
||||
QTC_ASSERT(state() == InferiorStarting, qDebug() << state());
|
||||
if (response.resultClass == GdbResultDone) {
|
||||
@@ -170,7 +170,7 @@ void CoreGdbAdapter::shutdown()
|
||||
QTC_ASSERT(state() == AdapterNotRunning, qDebug() << state());
|
||||
}
|
||||
|
||||
void CoreGdbAdapter::handleExit(const GdbResultRecord &response, const QVariant &)
|
||||
void CoreGdbAdapter::handleExit(const GdbResponse &response)
|
||||
{
|
||||
if (response.resultClass == GdbResultDone) {
|
||||
// don't set state here, this will be handled in handleGdbFinished()
|
||||
|
||||
@@ -67,11 +67,10 @@ private:
|
||||
void interruptInferior();
|
||||
void shutdown();
|
||||
|
||||
void handleFileExecAndSymbols(const GdbResultRecord &, const QVariant &);
|
||||
void handleTargetCore(const GdbResultRecord &response, const QVariant &);
|
||||
void handleExit(const GdbResultRecord &, const QVariant &);
|
||||
void handleFileExecAndSymbols(const GdbResponse &response);
|
||||
void handleTargetCore(const GdbResponse &response);
|
||||
void handleExit(const GdbResponse &response);
|
||||
|
||||
void debugMessage(const QString &msg) { m_engine->debugMessage(msg); }
|
||||
Q_SLOT void handleGdbFinished(int, QProcess::ExitStatus);
|
||||
Q_SLOT void handleGdbStarted();
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -59,7 +59,7 @@ namespace Internal {
|
||||
class AbstractGdbAdapter;
|
||||
class DebuggerManager;
|
||||
class IDebuggerManagerAccessForEngines;
|
||||
class GdbResultRecord;
|
||||
class GdbResponse;
|
||||
class GdbMi;
|
||||
|
||||
class BreakpointData;
|
||||
@@ -135,18 +135,15 @@ private:
|
||||
virtual QList<Symbol> moduleSymbols(const QString &moduleName);
|
||||
|
||||
void fetchMemory(MemoryViewAgent *agent, quint64 addr, quint64 length);
|
||||
void handleFetchMemory(const GdbResultRecord &record, const QVariant &cookie);
|
||||
void handleFetchMemory(const GdbResponse &response);
|
||||
|
||||
void fetchDisassembler(DisassemblerViewAgent *agent,
|
||||
const StackFrame &frame);
|
||||
void fetchDisassemblerByAddress(DisassemblerViewAgent *agent,
|
||||
bool useMixedMode);
|
||||
void handleFetchDisassemblerByLine(const GdbResultRecord &record,
|
||||
const QVariant &cookie);
|
||||
void handleFetchDisassemblerByAddress1(const GdbResultRecord &record,
|
||||
const QVariant &cookie);
|
||||
void handleFetchDisassemblerByAddress0(const GdbResultRecord &record,
|
||||
const QVariant &cookie);
|
||||
void handleFetchDisassemblerByLine(const GdbResponse &response);
|
||||
void handleFetchDisassemblerByAddress1(const GdbResponse &response);
|
||||
void handleFetchDisassemblerByAddress0(const GdbResponse &response);
|
||||
|
||||
Q_SLOT void setDebugDebuggingHelpers(const QVariant &on);
|
||||
Q_SLOT void setUseDebuggingHelpers(const QVariant &on);
|
||||
@@ -167,7 +164,7 @@ private:
|
||||
// get one usable name out of these, try full names first
|
||||
QString fullName(const QStringList &candidates);
|
||||
|
||||
void handleResult(const GdbResultRecord &, int type, const QVariant &);
|
||||
void handleResult(const GdbResponse &response);
|
||||
|
||||
public: // otherwise the Qt flag macros are unhappy
|
||||
enum GdbCommandFlag {
|
||||
@@ -183,9 +180,9 @@ public: // otherwise the Qt flag macros are unhappy
|
||||
|
||||
private:
|
||||
typedef void (GdbEngine::*GdbCommandCallback)
|
||||
(const GdbResultRecord &record, const QVariant &cookie);
|
||||
(const GdbResponse &response);
|
||||
typedef void (AbstractGdbAdapter::*AdapterCallback)
|
||||
(const GdbResultRecord &record, const QVariant &cookie);
|
||||
(const GdbResponse &response);
|
||||
|
||||
struct GdbCommand
|
||||
{
|
||||
@@ -254,24 +251,24 @@ private slots:
|
||||
private:
|
||||
int terminationIndex(const QByteArray &buffer, int &length);
|
||||
void handleResponse(const QByteArray &buff);
|
||||
void handleStart(const GdbResultRecord &response, const QVariant &);
|
||||
void handleStart(const GdbResponse &response);
|
||||
void handleAqcuiredInferior();
|
||||
void handleAsyncOutput(const GdbMi &data);
|
||||
void handleStop1(const GdbResultRecord &, const QVariant &cookie);
|
||||
void handleStop2(const GdbResultRecord &, const QVariant &cookie);
|
||||
void handleStop1(const GdbResponse &response);
|
||||
void handleStop2(const GdbResponse &response);
|
||||
void handleStop2(const GdbMi &data);
|
||||
void handleResultRecord(const GdbResultRecord &response);
|
||||
void handleFileExecAndSymbols(const GdbResultRecord &response, const QVariant &);
|
||||
void handleExecContinue(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 &);
|
||||
void handleInfoProc(const GdbResultRecord &response, const QVariant &);
|
||||
void handleInfoThreads(const GdbResultRecord &response, const QVariant &);
|
||||
void handleShowVersion(const GdbResultRecord &response, const QVariant &);
|
||||
void handleQueryPwd(const GdbResultRecord &response, const QVariant &);
|
||||
void handleQuerySources(const GdbResultRecord &response, const QVariant &);
|
||||
void handleWatchPoint(const GdbResultRecord &, const QVariant &);
|
||||
void handleResultRecord(const GdbResponse &response);
|
||||
void handleFileExecAndSymbols(const GdbResponse &response);
|
||||
void handleExecContinue(const GdbResponse &response);
|
||||
void handleExecJumpToLine(const GdbResponse &response);
|
||||
void handleExecRunToFunction(const GdbResponse &response);
|
||||
void handleInfoShared(const GdbResponse &response);
|
||||
void handleInfoProc(const GdbResponse &response);
|
||||
void handleInfoThreads(const GdbResponse &response);
|
||||
void handleShowVersion(const GdbResponse &response);
|
||||
void handleQueryPwd(const GdbResponse &response);
|
||||
void handleQuerySources(const GdbResponse &response);
|
||||
void handleWatchPoint(const GdbResponse &response);
|
||||
bool showToolTip();
|
||||
|
||||
// Convenience
|
||||
@@ -314,13 +311,13 @@ private:
|
||||
//
|
||||
// Breakpoint specific stuff
|
||||
//
|
||||
void handleBreakList(const GdbResultRecord &record, const QVariant &);
|
||||
void handleBreakList(const GdbResponse &response);
|
||||
void handleBreakList(const GdbMi &table);
|
||||
void handleBreakIgnore(const GdbResultRecord &record, const QVariant &cookie);
|
||||
void handleBreakInsert(const GdbResultRecord &record, const QVariant &cookie);
|
||||
void handleBreakInsert1(const GdbResultRecord &record, const QVariant &cookie);
|
||||
void handleBreakCondition(const GdbResultRecord &record, const QVariant &cookie);
|
||||
void handleBreakInfo(const GdbResultRecord &record, const QVariant &cookie);
|
||||
void handleBreakIgnore(const GdbResponse &response);
|
||||
void handleBreakInsert(const GdbResponse &response);
|
||||
void handleBreakInsert1(const GdbResponse &response);
|
||||
void handleBreakCondition(const GdbResponse &response);
|
||||
void handleBreakInfo(const GdbResponse &response);
|
||||
void extractDataFromInfoBreak(const QString &output, BreakpointData *data);
|
||||
void breakpointDataFromOutput(BreakpointData *data, const GdbMi &bkpt);
|
||||
void sendInsertBreakpoint(int index);
|
||||
@@ -329,7 +326,7 @@ private:
|
||||
// Modules specific stuff
|
||||
//
|
||||
void reloadModules();
|
||||
void handleModulesList(const GdbResultRecord &record, const QVariant &);
|
||||
void handleModulesList(const GdbResponse &response);
|
||||
|
||||
|
||||
//
|
||||
@@ -337,8 +334,8 @@ private:
|
||||
//
|
||||
Q_SLOT void reloadRegisters();
|
||||
void setRegisterValue(int nr, const QString &value);
|
||||
void handleRegisterListNames(const GdbResultRecord &record, const QVariant &);
|
||||
void handleRegisterListValues(const GdbResultRecord &record, const QVariant &);
|
||||
void handleRegisterListNames(const GdbResponse &response);
|
||||
void handleRegisterListValues(const GdbResponse &response);
|
||||
|
||||
//
|
||||
// Source file specific stuff
|
||||
@@ -348,9 +345,9 @@ private:
|
||||
//
|
||||
// Stack specific stuff
|
||||
//
|
||||
void handleStackListFrames(const GdbResultRecord &record, const QVariant &cookie);
|
||||
void handleStackSelectThread(const GdbResultRecord &, const QVariant &);
|
||||
void handleStackListThreads(const GdbResultRecord &record, const QVariant &cookie);
|
||||
void handleStackListFrames(const GdbResponse &response);
|
||||
void handleStackSelectThread(const GdbResponse &response);
|
||||
void handleStackListThreads(const GdbResponse &response);
|
||||
Q_SLOT void reloadStack();
|
||||
Q_SLOT void reloadFullStack();
|
||||
|
||||
@@ -384,26 +381,19 @@ private:
|
||||
void runDirectDebuggingHelper(const WatchData &data, bool dumpChildren);
|
||||
bool hasDebuggingHelperForType(const QString &type) const;
|
||||
|
||||
void handleVarListChildren(const GdbResultRecord &record,
|
||||
const QVariant &cookie);
|
||||
void handleVarCreate(const GdbResultRecord &record,
|
||||
const QVariant &cookie);
|
||||
void handleVarAssign(const GdbResultRecord &, const QVariant &);
|
||||
void handleEvaluateExpression(const GdbResultRecord &record,
|
||||
const QVariant &cookie);
|
||||
//void handleToolTip(const GdbResultRecord &record,
|
||||
// const QVariant &cookie);
|
||||
void handleQueryDebuggingHelper(const GdbResultRecord &record, const QVariant &);
|
||||
void handleDebuggingHelperValue1(const GdbResultRecord &record,
|
||||
const QVariant &cookie);
|
||||
void handleDebuggingHelperValue2(const GdbResultRecord &record,
|
||||
const QVariant &cookie);
|
||||
void handleDebuggingHelperValue3(const GdbResultRecord &record,
|
||||
const QVariant &cookie);
|
||||
void handleDebuggingHelperEditValue(const GdbResultRecord &record);
|
||||
void handleDebuggingHelperSetup(const GdbResultRecord &record, const QVariant &);
|
||||
void handleStackListLocals(const GdbResultRecord &record, const QVariant &);
|
||||
void handleStackListArguments(const GdbResultRecord &record, const QVariant &);
|
||||
void handleVarListChildren(const GdbResponse &response);
|
||||
void handleVarCreate(const GdbResponse &response);
|
||||
void handleVarAssign(const GdbResponse &response);
|
||||
void handleEvaluateExpression(const GdbResponse &response);
|
||||
//void handleToolTip(const GdbResponse &response);
|
||||
void handleQueryDebuggingHelper(const GdbResponse &response);
|
||||
void handleDebuggingHelperValue1(const GdbResponse &response);
|
||||
void handleDebuggingHelperValue2(const GdbResponse &response);
|
||||
void handleDebuggingHelperValue3(const GdbResponse &response);
|
||||
void handleDebuggingHelperEditValue(const GdbResponse &response);
|
||||
void handleDebuggingHelperSetup(const GdbResponse &response);
|
||||
void handleStackListLocals(const GdbResponse &response);
|
||||
void handleStackListArguments(const GdbResponse &response);
|
||||
void handleVarListChildrenHelper(const GdbMi &child,
|
||||
const WatchData &parent);
|
||||
void setWatchDataType(WatchData &data, const GdbMi &mi);
|
||||
|
||||
@@ -358,7 +358,7 @@ GdbMi GdbMi::findChild(const char *name) const
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// GdbResultRecord
|
||||
// GdbResponse
|
||||
//
|
||||
//////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@@ -374,7 +374,7 @@ QByteArray stringFromResultClass(GdbResultClass resultClass)
|
||||
}
|
||||
};
|
||||
|
||||
QByteArray GdbResultRecord::toString() const
|
||||
QByteArray GdbResponse::toString() const
|
||||
{
|
||||
QByteArray result;
|
||||
if (token != -1)
|
||||
|
||||
@@ -32,6 +32,7 @@
|
||||
|
||||
#include <QtCore/QByteArray>
|
||||
#include <QtCore/QList>
|
||||
#include <QtCore/QVariant>
|
||||
|
||||
namespace Debugger {
|
||||
namespace Internal {
|
||||
@@ -128,7 +129,7 @@ public:
|
||||
void setStreamOutput(const QByteArray &name, const QByteArray &content);
|
||||
|
||||
private:
|
||||
friend class GdbResultRecord;
|
||||
friend class GdbResponse;
|
||||
friend class GdbEngine;
|
||||
|
||||
static QByteArray parseCString(const char *&from, const char *to);
|
||||
@@ -155,15 +156,16 @@ enum GdbResultClass
|
||||
GdbResultExit,
|
||||
};
|
||||
|
||||
class GdbResultRecord
|
||||
class GdbResponse
|
||||
{
|
||||
public:
|
||||
GdbResultRecord() : token(-1), resultClass(GdbResultUnknown) {}
|
||||
GdbResponse() : token(-1), resultClass(GdbResultUnknown) {}
|
||||
QByteArray toString() const;
|
||||
|
||||
int token;
|
||||
GdbResultClass resultClass;
|
||||
GdbMi data;
|
||||
QVariant cookie;
|
||||
};
|
||||
|
||||
} // namespace Internal
|
||||
|
||||
@@ -142,7 +142,7 @@ void PlainGdbAdapter::prepareInferior()
|
||||
CB(handleFileExecAndSymbols));
|
||||
}
|
||||
|
||||
void PlainGdbAdapter::handleFileExecAndSymbols(const GdbResultRecord &response, const QVariant &)
|
||||
void PlainGdbAdapter::handleFileExecAndSymbols(const GdbResponse &response)
|
||||
{
|
||||
QTC_ASSERT(state() == InferiorPreparing, qDebug() << state());
|
||||
if (response.resultClass == GdbResultDone) {
|
||||
@@ -157,7 +157,7 @@ void PlainGdbAdapter::handleFileExecAndSymbols(const GdbResultRecord &response,
|
||||
}
|
||||
}
|
||||
|
||||
void PlainGdbAdapter::handleInfoTarget(const GdbResultRecord &response, const QVariant &)
|
||||
void PlainGdbAdapter::handleInfoTarget(const GdbResponse &response)
|
||||
{
|
||||
QTC_ASSERT(state() == AdapterNotRunning, qDebug() << state());
|
||||
#if defined(Q_OS_MAC)
|
||||
@@ -199,7 +199,7 @@ void PlainGdbAdapter::handleInfoTarget(const GdbResultRecord &response, const QV
|
||||
#endif
|
||||
}
|
||||
|
||||
void PlainGdbAdapter::handleExecRun(const GdbResultRecord &response, const QVariant &)
|
||||
void PlainGdbAdapter::handleExecRun(const GdbResponse &response)
|
||||
{
|
||||
QTC_ASSERT(state() == InferiorStarting, qDebug() << state());
|
||||
if (response.resultClass == GdbResultRunning) {
|
||||
@@ -270,7 +270,7 @@ void PlainGdbAdapter::shutdown()
|
||||
QTC_ASSERT(state() == AdapterNotRunning, qDebug() << state());
|
||||
}
|
||||
|
||||
void PlainGdbAdapter::handleKill(const GdbResultRecord &response, const QVariant &)
|
||||
void PlainGdbAdapter::handleKill(const GdbResponse &response)
|
||||
{
|
||||
if (response.resultClass == GdbResultDone) {
|
||||
setState(InferiorShutDown);
|
||||
@@ -284,7 +284,7 @@ void PlainGdbAdapter::handleKill(const GdbResultRecord &response, const QVariant
|
||||
}
|
||||
}
|
||||
|
||||
void PlainGdbAdapter::handleExit(const GdbResultRecord &response, const QVariant &)
|
||||
void PlainGdbAdapter::handleExit(const GdbResponse &response)
|
||||
{
|
||||
if (response.resultClass == GdbResultDone) {
|
||||
// don't set state here, this will be handled in handleGdbFinished()
|
||||
@@ -309,12 +309,11 @@ void PlainGdbAdapter::stubStarted()
|
||||
m_engine->postCommand(_("attach %1").arg(attachedPID), CB(handleStubAttached));
|
||||
}
|
||||
|
||||
void PlainGdbAdapter::handleStubAttached(const GdbResultRecord &, const QVariant &)
|
||||
void PlainGdbAdapter::handleStubAttached(const GdbResponse &)
|
||||
{
|
||||
qDebug() << "STUB ATTACHED, FIXME";
|
||||
//qq->notifyInferiorStopped();
|
||||
//handleAqcuiredInferior();
|
||||
// FIXME: m_autoContinue = true;
|
||||
}
|
||||
|
||||
void PlainGdbAdapter::stubError(const QString &msg)
|
||||
|
||||
@@ -69,14 +69,13 @@ public:
|
||||
void shutdown();
|
||||
|
||||
private:
|
||||
void handleFileExecAndSymbols(const GdbResultRecord &, const QVariant &);
|
||||
void handleKill(const GdbResultRecord &, const QVariant &);
|
||||
void handleExit(const GdbResultRecord &, const QVariant &);
|
||||
void handleStubAttached(const GdbResultRecord &, const QVariant &);
|
||||
void handleExecRun(const GdbResultRecord &response, const QVariant &);
|
||||
void handleInfoTarget(const GdbResultRecord &response, const QVariant &);
|
||||
void handleFileExecAndSymbols(const GdbResponse &response);
|
||||
void handleKill(const GdbResponse &response);
|
||||
void handleExit(const GdbResponse &response);
|
||||
void handleStubAttached(const GdbResponse &response);
|
||||
void handleExecRun(const GdbResponse &response);
|
||||
void handleInfoTarget(const GdbResponse &response);
|
||||
|
||||
void debugMessage(const QString &msg) { m_engine->debugMessage(msg); }
|
||||
void emitAdapterStartFailed(const QString &msg);
|
||||
Q_SLOT void handleGdbFinished(int, QProcess::ExitStatus);
|
||||
Q_SLOT void handleGdbStarted();
|
||||
|
||||
@@ -201,7 +201,7 @@ void RemoteGdbAdapter::prepareInferior()
|
||||
//emit inferiorPreparationFailed(msg);
|
||||
}
|
||||
|
||||
void RemoteGdbAdapter::handleFileExecAndSymbols(const GdbResultRecord &response, const QVariant &)
|
||||
void RemoteGdbAdapter::handleFileExecAndSymbols(const GdbResponse &response)
|
||||
{
|
||||
QTC_ASSERT(state() == InferiorPreparing, qDebug() << state());
|
||||
if (response.resultClass == GdbResultDone) {
|
||||
@@ -217,7 +217,7 @@ void RemoteGdbAdapter::handleFileExecAndSymbols(const GdbResultRecord &response,
|
||||
}
|
||||
}
|
||||
|
||||
void RemoteGdbAdapter::handleTargetRemote(const GdbResultRecord &record, const QVariant &)
|
||||
void RemoteGdbAdapter::handleTargetRemote(const GdbResponse &record)
|
||||
{
|
||||
QTC_ASSERT(state() == InferiorPreparing, qDebug() << state());
|
||||
if (record.resultClass == GdbResultDone) {
|
||||
@@ -242,7 +242,7 @@ void RemoteGdbAdapter::startInferior()
|
||||
emit inferiorStarted();
|
||||
}
|
||||
|
||||
void RemoteGdbAdapter::handleFirstContinue(const GdbResultRecord &record, const QVariant &)
|
||||
void RemoteGdbAdapter::handleFirstContinue(const GdbResponse &record)
|
||||
{
|
||||
//QTC_ASSERT(state() == InferiorStarting, qDebug() << state());
|
||||
QTC_ASSERT(state() == InferiorStarted, qDebug() << state());
|
||||
@@ -285,7 +285,7 @@ void RemoteGdbAdapter::shutdown()
|
||||
}
|
||||
}
|
||||
|
||||
void RemoteGdbAdapter::handleKill(const GdbResultRecord &response, const QVariant &)
|
||||
void RemoteGdbAdapter::handleKill(const GdbResponse &response)
|
||||
{
|
||||
if (response.resultClass == GdbResultDone) {
|
||||
setState(InferiorShutDown);
|
||||
@@ -299,7 +299,7 @@ void RemoteGdbAdapter::handleKill(const GdbResultRecord &response, const QVarian
|
||||
}
|
||||
}
|
||||
|
||||
void RemoteGdbAdapter::handleExit(const GdbResultRecord &response, const QVariant &)
|
||||
void RemoteGdbAdapter::handleExit(const GdbResponse &response)
|
||||
{
|
||||
if (response.resultClass == GdbResultDone) {
|
||||
// don't set state here, this will be handled in handleGdbFinished()
|
||||
|
||||
@@ -71,13 +71,12 @@ private:
|
||||
Q_SLOT void readUploadStandardError();
|
||||
Q_SLOT void uploadProcError(QProcess::ProcessError error);
|
||||
|
||||
void handleFileExecAndSymbols(const GdbResultRecord &, const QVariant &);
|
||||
void handleKill(const GdbResultRecord &, const QVariant &);
|
||||
void handleExit(const GdbResultRecord &, const QVariant &);
|
||||
void handleTargetRemote(const GdbResultRecord &response, const QVariant &);
|
||||
void handleFirstContinue(const GdbResultRecord &response, const QVariant &);
|
||||
void handleFileExecAndSymbols(const GdbResponse &response);
|
||||
void handleKill(const GdbResponse &response);
|
||||
void handleExit(const GdbResponse &response);
|
||||
void handleTargetRemote(const GdbResponse &response);
|
||||
void handleFirstContinue(const GdbResponse &response);
|
||||
|
||||
void debugMessage(const QString &msg) { m_engine->debugMessage(msg); }
|
||||
Q_SLOT void handleGdbFinished(int, QProcess::ExitStatus);
|
||||
Q_SLOT void handleGdbStarted();
|
||||
|
||||
|
||||
@@ -1391,7 +1391,7 @@ void TrkGdbAdapter::prepareInferior()
|
||||
CB(handleTargetRemote));
|
||||
}
|
||||
|
||||
void TrkGdbAdapter::handleTargetRemote(const GdbResultRecord &record, const QVariant &)
|
||||
void TrkGdbAdapter::handleTargetRemote(const GdbResponse &record)
|
||||
{
|
||||
QTC_ASSERT(state() == InferiorPreparing, qDebug() << state());
|
||||
if (record.resultClass == GdbResultDone) {
|
||||
@@ -1414,7 +1414,7 @@ void TrkGdbAdapter::startInferior()
|
||||
emit inferiorStarted();
|
||||
}
|
||||
|
||||
void TrkGdbAdapter::handleFirstContinue(const GdbResultRecord &record, const QVariant &)
|
||||
void TrkGdbAdapter::handleFirstContinue(const GdbResponse &record)
|
||||
{
|
||||
//QTC_ASSERT(state() == InferiorStarting, qDebug() << state());
|
||||
QTC_ASSERT(state() == InferiorStarted, qDebug() << state());
|
||||
@@ -1608,7 +1608,7 @@ void TrkGdbAdapter::shutdown()
|
||||
QTC_ASSERT(state() == AdapterNotRunning, qDebug() << state());
|
||||
}
|
||||
|
||||
void TrkGdbAdapter::handleKill(const GdbResultRecord &response, const QVariant &)
|
||||
void TrkGdbAdapter::handleKill(const GdbResponse &response)
|
||||
{
|
||||
if (response.resultClass == GdbResultDone) {
|
||||
setState(InferiorShutDown);
|
||||
@@ -1622,7 +1622,7 @@ void TrkGdbAdapter::handleKill(const GdbResultRecord &response, const QVariant &
|
||||
}
|
||||
}
|
||||
|
||||
void TrkGdbAdapter::handleExit(const GdbResultRecord &response, const QVariant &)
|
||||
void TrkGdbAdapter::handleExit(const GdbResponse &response)
|
||||
{
|
||||
if (response.resultClass == GdbResultDone) {
|
||||
qDebug() << "EXITED, NO MESSAGE...";
|
||||
|
||||
@@ -100,7 +100,6 @@ private:
|
||||
QProcess m_gdbProc;
|
||||
QProcess m_rfcommProc;
|
||||
bool m_running;
|
||||
void debugMessage(const QString &msg) { m_engine->debugMessage(msg); }
|
||||
|
||||
public:
|
||||
//
|
||||
@@ -123,10 +122,10 @@ public:
|
||||
void shutdown();
|
||||
|
||||
Q_SLOT void startInferiorEarly();
|
||||
void handleKill(const GdbResultRecord &, const QVariant &);
|
||||
void handleExit(const GdbResultRecord &, const QVariant &);
|
||||
void handleTargetRemote(const GdbResultRecord &, const QVariant &);
|
||||
void handleFirstContinue(const GdbResultRecord &, const QVariant &);
|
||||
void handleKill(const GdbResponse &response);
|
||||
void handleExit(const GdbResponse &response);
|
||||
void handleTargetRemote(const GdbResponse &response);
|
||||
void handleFirstContinue(const GdbResponse &response);
|
||||
|
||||
//
|
||||
// TRK
|
||||
|
||||
Reference in New Issue
Block a user