From f4c3b53cd13aa3b3983fe05abb026a19d597df66 Mon Sep 17 00:00:00 2001 From: MihailRis Date: Thu, 9 Oct 2025 00:28:06 +0300 Subject: [PATCH] replace 'hit-breakpoint' with 'paused' --- res/scripts/stdmin.lua | 2 +- src/devtools/DebuggingServer.cpp | 14 ++++++-------- 2 files changed, 7 insertions(+), 9 deletions(-) diff --git a/res/scripts/stdmin.lua b/res/scripts/stdmin.lua index 3e07c26b..8c9e0a42 100644 --- a/res/scripts/stdmin.lua +++ b/res/scripts/stdmin.lua @@ -41,7 +41,7 @@ debug.sethook(function (e, line) end end current_func = func - __pause() + __pause("step") debug.pull_events() end hook_lock = false diff --git a/src/devtools/DebuggingServer.cpp b/src/devtools/DebuggingServer.cpp index 505f1ff5..a9a32667 100644 --- a/src/devtools/DebuggingServer.cpp +++ b/src/devtools/DebuggingServer.cpp @@ -219,14 +219,12 @@ void DebuggingServer::pause( if (connection == nullptr) { return; } - if (stackTrace != nullptr) { - connection->send(dv::object({ - {"type", std::string("hit-breakpoint")}, - {"reason", std::move(reason)}, - {"message", std::move(message)}, - {"stack", std::move(stackTrace)} - })); - } + connection->send(dv::object({ + {"type", std::string("paused")}, + {"reason", std::move(reason)}, + {"message", std::move(message)}, + {"stack", std::move(stackTrace)} + })); engine.startPauseLoop(); }