From 2dda5648661f68b2dc6bdfb3dc43466cda06e35e Mon Sep 17 00:00:00 2001 From: Xusheng Date: Thu, 9 Apr 2026 14:52:40 +0800 Subject: [PATCH] Avoid creating a new DebuggerController in a UI isValid callback. Fix https://github.com/Vector35/debugger/issues/1058 --- ui/ui.cpp | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/ui/ui.cpp b/ui/ui.cpp index ec245d0b..793167f2 100644 --- a/ui/ui.cpp +++ b/ui/ui.cpp @@ -537,12 +537,7 @@ void GlobalDebuggerUI::SetupMenu(UIContext* context) if (!controller->RebaseToAddress(address)) LogWarn("Failed to rebase to address 0x%" PRIx64, address); }, - [=](const UIActionContext& ctxt) { - if (!ctxt.binaryView) - return false; - const auto controller = DebuggerController::GetController(ctxt.binaryView); - return controller && controller->IsConnected(); - })); + connected)); debuggerMenu->addAction("Rebase to Remote Base...", "Rebase");