Commit 0155f11c authored by hjk's avatar hjk
Browse files

debugger: fix regression in disassembler listing introduced in 37c98f89

parent ca47f5d1
...@@ -194,6 +194,7 @@ DisassemblerViewAgent::~DisassemblerViewAgent() ...@@ -194,6 +194,7 @@ DisassemblerViewAgent::~DisassemblerViewAgent()
if (d->editor) if (d->editor)
d->editor->deleteLater(); d->editor->deleteLater();
delete d; delete d;
d = 0;
} }
void DisassemblerViewAgent::setFrame(const StackFrame &frame) void DisassemblerViewAgent::setFrame(const StackFrame &frame)
...@@ -207,12 +208,10 @@ void DisassemblerViewAgent::setFrame(const StackFrame &frame) ...@@ -207,12 +208,10 @@ void DisassemblerViewAgent::setFrame(const StackFrame &frame)
void DisassemblerViewAgent::setContents(const QString &contents) void DisassemblerViewAgent::setContents(const QString &contents)
{ {
QTC_ASSERT(d, return);
using namespace Core; using namespace Core;
using namespace TextEditor; using namespace TextEditor;
if (!d->editor)
return;
QPlainTextEdit *plainTextEdit = 0; QPlainTextEdit *plainTextEdit = 0;
EditorManager *editorManager = EditorManager::instance(); EditorManager *editorManager = EditorManager::instance();
if (!d->editor) { if (!d->editor) {
......
...@@ -3827,7 +3827,7 @@ struct MemoryAgentCookie ...@@ -3827,7 +3827,7 @@ struct MemoryAgentCookie
MemoryAgentCookie(MemoryViewAgent *agent_, quint64 address_) MemoryAgentCookie(MemoryViewAgent *agent_, quint64 address_)
: agent(agent_), address(address_) : agent(agent_), address(address_)
{} {}
MemoryViewAgent *agent; QPointer<MemoryViewAgent> agent;
quint64 address; quint64 address;
}; };
...@@ -3870,7 +3870,7 @@ struct DisassemblerAgentCookie ...@@ -3870,7 +3870,7 @@ struct DisassemblerAgentCookie
DisassemblerAgentCookie(DisassemblerViewAgent *agent_) DisassemblerAgentCookie(DisassemblerViewAgent *agent_)
: agent(agent_) : agent(agent_)
{} {}
DisassemblerViewAgent *agent; QPointer<DisassemblerViewAgent> agent;
}; };
void GdbEngine::fetchDisassembler(DisassemblerViewAgent *agent, void GdbEngine::fetchDisassembler(DisassemblerViewAgent *agent,
......
Supports Markdown
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