debugger: prepare naive handling of multiple inferiors

Change-Id: I2ea81b1a9407ae7e5045aadf43b0c2d971fc615b
Reviewed-by: hjk <qthjk@ovi.com>
This commit is contained in:
hjk
2012-03-28 09:37:02 +02:00
committed by hjk
parent 66cf82a457
commit f67c6dba11
6 changed files with 75 additions and 15 deletions

View File

@@ -423,6 +423,7 @@ void GdbEngine::handleResponse(const QByteArray &buff)
}
if (pid)
notifyInferiorPid(pid);
handleThreadGroupCreated(result);
} else if (asyncClass == "thread-created") {
//"{id="1",group-id="28902"}"
QByteArray id = result.findChild("id").data();
@@ -431,6 +432,7 @@ void GdbEngine::handleResponse(const QByteArray &buff)
// Archer has "{id="28902"}"
QByteArray id = result.findChild("id").data();
showStatusMessage(tr("Thread group %1 exited").arg(_(id)), 1000);
handleThreadGroupExited(result);
} else if (asyncClass == "thread-exited") {
//"{id="1",group-id="28902"}"
QByteArray id = result.findChild("id").data();
@@ -1725,6 +1727,9 @@ void GdbEngine::handleShowVersion(const GdbResponse &response)
postCommand("set target-async on", ConsoleCommand);
else
postCommand("set target-async off", ConsoleCommand);
if (startParameters().multiProcess)
postCommand("set detach-on-fork off", ConsoleCommand);
}
}
@@ -1988,6 +1993,18 @@ void GdbEngine::handleDetach(const GdbResponse &response)
notifyInferiorExited();
}
void GdbEngine::handleThreadGroupCreated(const GdbMi &result)
{
QByteArray id = result.findChild("id").data();
QByteArray pid = result.findChild("pid").data();
Q_UNUSED(pid);
}
void GdbEngine::handleThreadGroupExited(const GdbMi &result)
{
QByteArray id = result.findChild("id").data();
}
int GdbEngine::currentFrame() const
{
return stackHandler()->currentIndex();