MCPcopy Create free account
hub / github.com/Norbyte/ositools / BreakpointInServerThread

Method BreakpointInServerThread

OsiInterface/Debugger.cpp:830–858  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

828 }
829
830 void Debugger::BreakpointInServerThread()
831 {
832 if (callStack_.empty()) {
833 Fail("Tried to trigger breakpoint with empty callstack");
834 }
835
836 auto const & lastFrame = *callStack_.rbegin();
837 Debug("Debugger::BreakpointInServerThread(): type %d", lastFrame.frameType);
838 {
839 std::unique_lock<std::mutex> lk(breakpointMutex_);
840 isPaused_ = true;
841 }
842
843 QueryResultInfo * queryResults = nullptr;
844 if (hasLastQueryInfo_
845 && callStack_.size() == lastQueryDepth_ - 1)
846 {
847 queryResults = &lastQueryResults_;
848 }
849
850 messageHandler_.SendBreakpointTriggered(callStack_, queryResults);
851
852 {
853 std::unique_lock<std::mutex> lk(breakpointMutex_);
854 breakpointCv_.wait(lk, [this]() { this->ServerThreadReentry(); return !this->isPaused_; });
855 }
856
857 Debug("Continuing from breakpoint.");
858 }
859
860 void Debugger::GlobalBreakpointInServerThread(GlobalBreakpointReason reason)
861 {

Callers

nothing calls this directly

Calls 4

ServerThreadReentryMethod · 0.95
DebugFunction · 0.85
FailFunction · 0.70

Tested by

no test coverage detected