Commit 974bfe37 authored by hjk's avatar hjk
Browse files

debugger: remove/update some cruft

parent 6a7cbac0
...@@ -538,9 +538,9 @@ void GdbEngine::handleResponse(const QByteArray &buff) ...@@ -538,9 +538,9 @@ void GdbEngine::handleResponse(const QByteArray &buff)
//if (state() == InferiorStopOk) { // Result of manual command. //if (state() == InferiorStopOk) { // Result of manual command.
// resetLocation(); // resetLocation();
// setTokenBarrier(); // setTokenBarrier();
// setState(InferiorRunRequested); // notifyInferiorRunRequested();
//} //}
//setState(InferiorRunOk); //notifyInferiorRunOk();
//showStatusMessage(tr("Running...")); //showStatusMessage(tr("Running..."));
response.resultClass = GdbResultRunning; response.resultClass = GdbResultRunning;
} else if (resultClass == "connected") { } else if (resultClass == "connected") {
...@@ -752,16 +752,6 @@ void GdbEngine::postCommandHelper(const GdbCommand &cmd) ...@@ -752,16 +752,6 @@ void GdbEngine::postCommandHelper(const GdbCommand &cmd)
showMessage(_("CHILD ALREADY BEING INTERRUPTED. STILL HOPING.")); showMessage(_("CHILD ALREADY BEING INTERRUPTED. STILL HOPING."));
// Calling shutdown() here breaks all situations where two // Calling shutdown() here breaks all situations where two
// NeedsStop commands are issued in quick succession. // NeedsStop commands are issued in quick succession.
//} else if (state() == InferiorStopRequested_Kill) {
// showMessage(_("CHILD ALREADY BEING INTERRUPTED (KILL PENDING)"));
// // FIXME
// shutdown();
//} else if (state() == InferiorRunRequested) {
// if (cmd.flags & LosesChild)
// setState(InferiorRunRequested_Kill);
// showMessage(_("RUNNING REQUESTED; POSTPONING INTERRUPT"));
//} else if (state() == InferiorRunRequested_Kill) {
// showMessage(_("RUNNING REQUESTED; POSTPONING INTERRUPT (KILL PENDING)"));
} else if (state() == InferiorRunOk) { } else if (state() == InferiorRunOk) {
showStatusMessage(tr("Stopping temporarily"), 1000); showStatusMessage(tr("Stopping temporarily"), 1000);
interruptInferiorTemporarily(); interruptInferiorTemporarily();
...@@ -818,7 +808,7 @@ void GdbEngine::flushCommand(const GdbCommand &cmd0) ...@@ -818,7 +808,7 @@ void GdbEngine::flushCommand(const GdbCommand &cmd0)
m_commandTimer->start(); m_commandTimer->start();
//if (cmd.flags & LosesChild) //if (cmd.flags & LosesChild)
// setState(InferiorShutdownRequested); // notifyInferiorIll();
} }
int GdbEngine::commandTimeoutTime() const int GdbEngine::commandTimeoutTime() const
...@@ -914,8 +904,7 @@ void GdbEngine::handleResultRecord(GdbResponse *response) ...@@ -914,8 +904,7 @@ void GdbEngine::handleResultRecord(GdbResponse *response)
// and library load messages. // and library load messages.
showMessage(_("APPLYING WORKAROUND #4")); showMessage(_("APPLYING WORKAROUND #4"));
notifyInferiorStopOk(); notifyInferiorStopOk();
//setState(InferiorShutdownRequested); //notifyInferiorIll();
//setState(InferiorShutdownOk);
//showStatusMessage(tr("Executable failed: %1") //showStatusMessage(tr("Executable failed: %1")
// .arg(QString::fromLocal8Bit(msg))); // .arg(QString::fromLocal8Bit(msg)));
//shutdown(); //shutdown();
...@@ -1119,7 +1108,7 @@ void GdbEngine::handleExecuteRunToFunction(const GdbResponse &response) ...@@ -1119,7 +1108,7 @@ void GdbEngine::handleExecuteRunToFunction(const GdbResponse &response)
// func="foo",args=[{name="str",value="@0x7fff0f450460"}], // func="foo",args=[{name="str",value="@0x7fff0f450460"}],
// file="main.cpp",fullname="/tmp/g/main.cpp",line="37"} // file="main.cpp",fullname="/tmp/g/main.cpp",line="37"}
QTC_ASSERT(state() == InferiorStopRequested, qDebug() << state()) QTC_ASSERT(state() == InferiorStopRequested, qDebug() << state())
setState(InferiorStopOk); notifyInferiorStopOk();
showStatusMessage(tr("Function reached. Stopped")); showStatusMessage(tr("Function reached. Stopped"));
GdbMi frame = response.data.findChild("frame"); GdbMi frame = response.data.findChild("frame");
StackFrame f = parseStackFrame(frame, 0); StackFrame f = parseStackFrame(frame, 0);
...@@ -4226,7 +4215,7 @@ void GdbEngine::handleGdbError(QProcess::ProcessError error) ...@@ -4226,7 +4215,7 @@ void GdbEngine::handleGdbError(QProcess::ProcessError error)
case QProcess::Timedout: case QProcess::Timedout:
default: default:
//gdbProc()->kill(); //gdbProc()->kill();
//setState(EngineShutdownRequested, true); //notifyEngineIll();
showMessageBox(QMessageBox::Critical, tr("Gdb I/O Error"), msg); showMessageBox(QMessageBox::Critical, tr("Gdb I/O Error"), msg);
break; break;
} }
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment