debugger: add support for temporary breakpoints

Change-Id: I841c37d21932da0ef354dbbe2fd75cec2fae86d6
Reviewed-by: hjk <qthjk@ovi.com>
This commit is contained in:
hjk
2012-08-21 14:16:07 +02:00
parent c2b78b8fdf
commit f671a58c79
6 changed files with 63 additions and 18 deletions

View File

@@ -633,8 +633,13 @@ void GdbEngine::handleResponse(const QByteArray &buff)
QByteArray nr = result.findChild("id").data();
BreakpointResponseId rid(nr);
BreakpointModelId id = handler->findBreakpointByResponseId(rid);
if (id.isValid())
handler->removeAlienBreakpoint(id);
if (id.isValid()) {
// This also triggers when a temporary breakpoint is hit.
// We do not really want that, as this loses all information.
// FIXME: Use a special marker for this case?
if (!handler->isOneShot(id))
handler->removeAlienBreakpoint(id);
}
} else {
qDebug() << "IGNORED ASYNC OUTPUT"
<< asyncClass << result.toString();
@@ -3140,6 +3145,10 @@ void GdbEngine::insertBreakpoint(BreakpointModelId id)
} else {
cmd = "-break-insert ";
}
if (handler->isOneShot(id))
cmd += "-t ";
//if (!data->condition.isEmpty())
// cmd += "-c " + data->condition + ' ';
cmd += breakpointLocation(id);