Prevent strange "section mentioned in a -j option but not found"
Alan Modra
amodra@gmail.com
Mon Jul 27 12:58:38 GMT 2020
"objdump -s -j .bss" results in a message that indicates objdump
couldn't find a .bss section when present. Fix that.
* objdump.c (dump_section): Don't return without calling
process_section_p.
diff --git a/binutils/objdump.c b/binutils/objdump.c
index 978d86cb1f..79ef051856 100644
--- a/binutils/objdump.c
+++ b/binutils/objdump.c
@@ -4283,10 +4283,10 @@ dump_section (bfd *abfd, asection *section, void *dummy ATTRIBUTE_UNUSED)
int count;
int width;
- if ((section->flags & SEC_HAS_CONTENTS) == 0)
+ if (! process_section_p (section))
return;
- if (! process_section_p (section))
+ if ((section->flags & SEC_HAS_CONTENTS) == 0)
return;
if ((datasize = bfd_section_size (section)) == 0)
--
Alan Modra
Australia Development Lab, IBM
More information about the Binutils
mailing list