mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-08 11:38:21 +02:00
Made DeleteBreakpoint not recursive
This commit is contained in:
parent
e4eb6dfcea
commit
c6446e7657
1 changed files with 44 additions and 41 deletions
|
@ -3576,13 +3576,15 @@ void WinDebugger::DeleteBreakpoint(Breakpoint* breakpoint)
|
|||
{
|
||||
AutoCrit autoCrit(mDebugManager->mCritSect);
|
||||
|
||||
if (breakpoint == mActiveBreakpoint)
|
||||
mActiveBreakpoint = NULL;
|
||||
|
||||
BfLogDbg("WinDebugger::DeleteBreakpoint %p Count:%d\n", breakpoint, mBreakpoints.size());
|
||||
|
||||
WdBreakpoint* wdBreakpoint = (WdBreakpoint*)breakpoint;
|
||||
|
||||
while (wdBreakpoint != NULL)
|
||||
{
|
||||
BfLogDbg("WinDebugger::DeleteBreakpoint %p Count:%d\n", wdBreakpoint, mBreakpoints.size());
|
||||
|
||||
if (wdBreakpoint == mActiveBreakpoint)
|
||||
mActiveBreakpoint = NULL;
|
||||
|
||||
if (wdBreakpoint->mCondition != NULL)
|
||||
{
|
||||
if (!wdBreakpoint->mIsLinkedSibling)
|
||||
|
@ -3624,10 +3626,11 @@ void WinDebugger::DeleteBreakpoint(Breakpoint* breakpoint)
|
|||
mBreakpoints.Remove(wdBreakpoint);
|
||||
}
|
||||
|
||||
if (wdBreakpoint->mLinkedSibling != NULL)
|
||||
DeleteBreakpoint(wdBreakpoint->mLinkedSibling);
|
||||
|
||||
auto nextBreakpoint = (WdBreakpoint*)wdBreakpoint->mLinkedSibling;
|
||||
delete wdBreakpoint;
|
||||
|
||||
wdBreakpoint = nextBreakpoint;
|
||||
}
|
||||
}
|
||||
|
||||
void WinDebugger::DetachBreakpoint(Breakpoint* breakpoint)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue