Commit a1ffc4a1 authored by Friedemann Kleint's avatar Friedemann Kleint

Debugger: Fix crash in stack frame layout display.

The option is also enabled when the index is invalid.

Task-number: QTCREATORBUG-5650
Change-Id: If1efb900d29724e5c43db1589c797197fae67bd2
Reviewed-on: http://codereview.qt.nokia.com/2342Reviewed-by: default avatarQt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: default avatarChristian Stenger <christian.stenger@nokia.com>
parent f7bd1277
......@@ -416,6 +416,7 @@ static inline void addStackLayoutMemoryView(DebuggerEngine *engine,
QWidget *parent)
{
typedef QPair<quint64, QString> RegisterValueNamePair;
QTC_ASSERT(engine && m, return ;)
// Determine suitable address range from locals
quint64 start = Q_UINT64_C(0xFFFFFFFFFFFFFFFF);
......@@ -895,7 +896,7 @@ void WatchWindow::contextMenuEvent(QContextMenuEvent *ev)
} else if (act == actOpenMemoryViewAtPointerValue) {
addVariableMemoryView(currentEngine(), true, mi0, true, ev->globalPos(), this);
} else if (act == actOpenMemoryEditorStackLayout) {
addStackLayoutMemoryView(currentEngine(), false, mi0.model(), ev->globalPos(), this);
addStackLayoutMemoryView(currentEngine(), false, model(), ev->globalPos(), this);
} else if (act == actSetWatchpointAtVariableAddress) {
setWatchpointAtAddress(address, size);
} else if (act == actSetWatchpointAtPointerValue) {
......
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