diff --git a/src/plugins/debugger/watchwindow.cpp b/src/plugins/debugger/watchwindow.cpp index 9bad66fcf90..51eabe54ba8 100644 --- a/src/plugins/debugger/watchwindow.cpp +++ b/src/plugins/debugger/watchwindow.cpp @@ -416,6 +416,7 @@ static inline void addStackLayoutMemoryView(DebuggerEngine *engine, QWidget *parent) { typedef QPair 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) {