Commit a1da6068 authored by hjk's avatar hjk

debugger: better protection from infinite loops due to broken dumpers in

synchroneous mode
parent f21b01fc
......@@ -3363,6 +3363,7 @@ void GdbEngine::updateLocals(const QVariant &cookie)
{
m_pendingRequests = 0;
if (isSynchroneous()) {
m_processedNames.clear();
manager()->watchHandler()->beginCycle();
m_toolTipExpression.clear();
QStringList expanded = m_manager->watchHandler()->expandedINames().toList();
......
......@@ -31,6 +31,7 @@
#include "watchutils.h"
#include "debuggeractions.h"
#include "debuggermanager.h"
#include "idebuggerengine.h"
#if USE_MODEL_TEST
#include "modeltest.h"
......@@ -1124,8 +1125,18 @@ void WatchHandler::insertData(const WatchData &data)
return;
}
if (data.isSomethingNeeded() && data.iname.contains('.')) {
MODEL_DEBUG("SOMETHING NEEDED: " << data.toString());
m_manager->updateWatchData(data);
MODEL_DEBUGX("SOMETHING NEEDED: " << data.toString());
if (!m_manager->currentEngine()->isSynchroneous()) {
m_manager->updateWatchData(data);
} else {
qDebug() << "ENDLESS LOOP: SOMETHING NEEDED: " << data.toString();
WatchData data1 = data;
data1.setAllUnneeded();
data1.setValue(QLatin1String("<unavailable synchroneous data>"));
data1.setHasChildren(false);
WatchModel *model = modelForIName(data.iname);
model->insertData(data1);
}
} else {
WatchModel *model = modelForIName(data.iname);
QTC_ASSERT(model, return);
......
Markdown is supported
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