mirror of
https://github.com/bminor/binutils-gdb.git
synced 2025-12-06 23:53:12 +00:00
Remove ALL_BREAKPOINTS_SAFE
There's just a single remaining use of the ALL_BREAKPOINTS_SAFE macro; this patch replaces it with a for-each and an explicit temporary variable.
This commit is contained in:
@@ -611,15 +611,6 @@ static int overlay_events_enabled;
|
||||
/* See description in breakpoint.h. */
|
||||
bool target_exact_watchpoints = false;
|
||||
|
||||
/* Walk the following statement or block through all breakpoints.
|
||||
ALL_BREAKPOINTS_SAFE does so even if the statement deletes the
|
||||
current breakpoint. */
|
||||
|
||||
#define ALL_BREAKPOINTS_SAFE(B,TMP) \
|
||||
for (B = breakpoint_chain; \
|
||||
B ? (TMP=B->next, 1): 0; \
|
||||
B = TMP)
|
||||
|
||||
/* Chains of all breakpoints defined. */
|
||||
|
||||
static struct breakpoint *breakpoint_chain;
|
||||
@@ -7617,9 +7608,9 @@ set_longjmp_breakpoint_for_call_dummy (void)
|
||||
void
|
||||
check_longjmp_breakpoint_for_call_dummy (struct thread_info *tp)
|
||||
{
|
||||
struct breakpoint *b, *b_tmp;
|
||||
|
||||
ALL_BREAKPOINTS_SAFE (b, b_tmp)
|
||||
for (struct breakpoint *b : all_breakpoints_safe ())
|
||||
{
|
||||
struct breakpoint *b_tmp = b->next;
|
||||
if (b->type == bp_longjmp_call_dummy && b->thread == tp->global_num)
|
||||
{
|
||||
struct breakpoint *dummy_b = b->related_breakpoint;
|
||||
@@ -7684,6 +7675,7 @@ check_longjmp_breakpoint_for_call_dummy (struct thread_info *tp)
|
||||
delete_breakpoint (b);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
enable_overlay_breakpoints (void)
|
||||
|
||||
Reference in New Issue
Block a user