Skip to content

Commit

Permalink
Do not mark the debugger binary view as dirty after the target has ex…
Browse files Browse the repository at this point in the history
…ited
  • Loading branch information
xusheng6 committed Dec 8, 2022
1 parent e614919 commit 594c90e
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions core/processview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ size_t DebugProcessMemoryView::PerformWrite(uint64_t offset, const void* data, s
void DebugProcessMemoryView::MarkDirty()
{
// This hack will let the views (linear/graph) update its display
ExecuteOnMainThread([this]() { BinaryView::NotifyDataWritten(0, 1); });
BinaryView::NotifyDataWritten(0, 1);
}


Expand All @@ -192,10 +192,8 @@ void DebugProcessMemoryView::eventHandler(const DebuggerEvent& event)
switch (event.type)
{
case TargetStoppedEventType:
case TargetExitedEventType:
case DetachedEventType:
case QuitDebuggingEventType:
case BackEndDisconnectedEventType:
// We should not call MarkDirty() in case of a TargetExitedEvent, since the debugger binary view is about to be
// deleted. And it can cause a crash in certain cases.
MarkDirty();
break;
default:
Expand Down

0 comments on commit 594c90e

Please sign in to comment.