forked from qt-creator/qt-creator
Debugger: Make DebuggerEngine::runCommand() virtual.
Allows default implementation of e.g. stack retrieval in the base class. Change-Id: I96460b19aa31347b2c863736b4ce2b5046eb4de6 Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com> Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
This commit is contained in:
@@ -60,10 +60,10 @@ void GdbPlainEngine::setupInferior()
|
||||
setEnvironmentVariables();
|
||||
if (!runParameters().processArgs.isEmpty()) {
|
||||
QString args = runParameters().processArgs;
|
||||
runCommand("-exec-arguments " + toLocalEncoding(args));
|
||||
runCommand({"-exec-arguments " + toLocalEncoding(args), NoFlags});
|
||||
}
|
||||
runCommand("-file-exec-and-symbols \"" + execFilePath() + '"',
|
||||
CB(handleFileExecAndSymbols));
|
||||
runCommand({"-file-exec-and-symbols \"" + execFilePath() + '"', NoFlags,
|
||||
CB(handleFileExecAndSymbols)});
|
||||
}
|
||||
|
||||
void GdbPlainEngine::handleFileExecAndSymbols(const DebuggerResponse &response)
|
||||
@@ -84,9 +84,9 @@ void GdbPlainEngine::handleFileExecAndSymbols(const DebuggerResponse &response)
|
||||
void GdbPlainEngine::runEngine()
|
||||
{
|
||||
if (runParameters().useContinueInsteadOfRun)
|
||||
runCommand("-exec-continue", CB(handleExecuteContinue), RunRequest);
|
||||
runCommand({"-exec-continue", RunRequest, CB(handleExecuteContinue)});
|
||||
else
|
||||
runCommand("-exec-run", CB(handleExecRun), RunRequest);
|
||||
runCommand({"-exec-run", RunRequest, CB(handleExecRun)});
|
||||
}
|
||||
void GdbPlainEngine::handleExecRun(const DebuggerResponse &response)
|
||||
{
|
||||
@@ -98,7 +98,7 @@ void GdbPlainEngine::handleExecRun(const DebuggerResponse &response)
|
||||
showMessage(msgInferiorSetupOk(), StatusBar);
|
||||
// FIXME: That's the wrong place for it.
|
||||
if (boolSetting(EnableReverseDebugging))
|
||||
runCommand("target record");
|
||||
runCommand({"target record", NoFlags});
|
||||
} else {
|
||||
QString msg = fromLocalEncoding(response.data["msg"].data());
|
||||
//QTC_CHECK(status() == InferiorRunOk);
|
||||
|
||||
Reference in New Issue
Block a user