summaryrefslogtreecommitdiff
path: root/gdb/maint.c
diff options
context:
space:
mode:
authorTom Tromey <tom@tromey.com>2023-04-10 10:43:32 -0600
committerTom Tromey <tom@tromey.com>2023-05-07 12:44:17 -0600
commit5250cbc85cbbf13221ed508c1b89f1ee0a6ac1ec (patch)
tree36230d533899f8a7459c129e1691944d82209b99 /gdb/maint.c
parent9ed8433a04bf0430e2da3cd44c18667859782410 (diff)
downloadbinutils-gdb-5250cbc85cbbf13221ed508c1b89f1ee0a6ac1ec.tar.gz
Remove ALL_OBJFILE_OSECTIONS
This replaces ALL_OBJFILE_OSECTIONS with an iterator so that for-each can be used.
Diffstat (limited to 'gdb/maint.c')
-rw-r--r--gdb/maint.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/maint.c b/gdb/maint.c
index 3cd2c5e899a..c5f2e5cdce0 100644
--- a/gdb/maint.c
+++ b/gdb/maint.c
@@ -566,9 +566,9 @@ maintenance_translate_address (const char *arg, int from_tty)
p = skip_spaces (p + 1);
for (objfile *objfile : current_program_space->objfiles ())
- ALL_OBJFILE_OSECTIONS (objfile, sect)
+ for (obj_section *iter : objfile->sections ())
{
- if (strncmp (sect->the_bfd_section->name, arg, arg_len) == 0)
+ if (strncmp (iter->the_bfd_section->name, arg, arg_len) == 0)
goto found;
}