MCPcopy Create free account
hub / github.com/beefytech/Beef / DetachBreakpoint

Method DetachBreakpoint

IDEHelper/WinDebugger.cpp:3831–3881  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3829}
3830
3831void WinDebugger::DetachBreakpoint(Breakpoint* breakpoint)
3832{
3833 AutoCrit autoCrit(mDebugManager->mCritSect);
3834
3835 BfLogDbg("WinDebugger::DetachBreakpoint %p\n", breakpoint);
3836
3837 WdBreakpoint* wdBreakpoint = (WdBreakpoint*)breakpoint;
3838
3839 if (wdBreakpoint->mAddr != 0)
3840 {
3841 mBreakpointAddrMap.Remove(wdBreakpoint->mAddr, wdBreakpoint);
3842 RemoveBreakpoint(wdBreakpoint->mAddr);
3843 if ((mDebuggerWaitingThread != NULL) && (mDebuggerWaitingThread->mIsAtBreakpointAddress == wdBreakpoint->mAddr))
3844 mDebuggerWaitingThread->mIsAtBreakpointAddress = NULL;
3845 if ((mDebuggerWaitingThread != NULL) && (mDebuggerWaitingThread->mBreakpointAddressContinuing == wdBreakpoint->mAddr))
3846 mDebuggerWaitingThread->mBreakpointAddressContinuing = NULL;
3847 wdBreakpoint->mLineData = DbgLineDataEx();
3848 wdBreakpoint->mAddr = 0;
3849 }
3850
3851 if (wdBreakpoint->mCondition != NULL)
3852 {
3853 delete wdBreakpoint->mCondition->mDbgEvaluationContext;
3854 wdBreakpoint->mCondition->mDbgEvaluationContext = NULL;
3855 }
3856
3857 if (wdBreakpoint->mMemoryBreakpointInfo != NULL)
3858 {
3859 for (int memoryWatchSlot = 0; memoryWatchSlot < 4; memoryWatchSlot++)
3860 {
3861 if (mMemoryBreakpoints[memoryWatchSlot].mBreakpoint == wdBreakpoint)
3862 {
3863 mFreeMemoryBreakIndices.push_back(memoryWatchSlot);
3864 mMemoryBreakpoints[memoryWatchSlot] = WdMemoryBreakpointBind();
3865 mMemoryBreakpointVersion++;
3866 UpdateThreadDebugRegisters();
3867 }
3868 }
3869
3870 wdBreakpoint->mMemoryBreakpointInfo->mMemoryWatchSlotBitmap = 0;
3871 }
3872
3873 if (wdBreakpoint->mLinkedSibling != NULL)
3874 {
3875 DeleteBreakpoint(wdBreakpoint->mLinkedSibling);
3876 wdBreakpoint->mLinkedSibling = NULL;
3877 }
3878
3879 wdBreakpoint->mSrcFile = NULL;
3880 wdBreakpoint->mPendingHotBindIdx = -1;
3881}
3882
3883void WinDebugger::MoveBreakpoint(Breakpoint* breakpoint, int lineNum, int wantColumn, bool rebindNow)
3884{

Callers

nothing calls this directly

Calls 4

DbgLineDataExClass · 0.85
RemoveMethod · 0.45
push_backMethod · 0.45

Tested by

no test coverage detected