mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-09 03:52:19 +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);
|
AutoCrit autoCrit(mDebugManager->mCritSect);
|
||||||
|
|
||||||
if (breakpoint == mActiveBreakpoint)
|
|
||||||
mActiveBreakpoint = NULL;
|
|
||||||
|
|
||||||
BfLogDbg("WinDebugger::DeleteBreakpoint %p Count:%d\n", breakpoint, mBreakpoints.size());
|
|
||||||
|
|
||||||
WdBreakpoint* wdBreakpoint = (WdBreakpoint*)breakpoint;
|
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->mCondition != NULL)
|
||||||
{
|
{
|
||||||
if (!wdBreakpoint->mIsLinkedSibling)
|
if (!wdBreakpoint->mIsLinkedSibling)
|
||||||
|
@ -3624,10 +3626,11 @@ void WinDebugger::DeleteBreakpoint(Breakpoint* breakpoint)
|
||||||
mBreakpoints.Remove(wdBreakpoint);
|
mBreakpoints.Remove(wdBreakpoint);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (wdBreakpoint->mLinkedSibling != NULL)
|
auto nextBreakpoint = (WdBreakpoint*)wdBreakpoint->mLinkedSibling;
|
||||||
DeleteBreakpoint(wdBreakpoint->mLinkedSibling);
|
|
||||||
|
|
||||||
delete wdBreakpoint;
|
delete wdBreakpoint;
|
||||||
|
|
||||||
|
wdBreakpoint = nextBreakpoint;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void WinDebugger::DetachBreakpoint(Breakpoint* breakpoint)
|
void WinDebugger::DetachBreakpoint(Breakpoint* breakpoint)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue