]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
readelf vs. mapping symbols
authorAlan Modra <amodra@gmail.com>
Fri, 30 Jan 2026 20:35:55 +0000 (07:05 +1030)
committerAlan Modra <amodra@gmail.com>
Fri, 30 Jan 2026 21:20:11 +0000 (07:50 +1030)
commitbd1dff62e881beec4183eb931041fc8840eed719
tree15264269d1797376238ba26bcc7cb088cb5485ad
parent05dba89586c351a189cd2782da3c1e2ab484532c
readelf vs. mapping symbols

This reverts commit 45cf0b829303, which isn't needed after commit
6d7e5bcca5.   Mapping symbols are like any other local symbol, and
shouldn't appear after the end of a section.

The real bug that resulted in both of these commits is that st_value
in an executable or shared library is the symbol address.  It was
wrong to compare an address against a section size (you'd need to
subtract off the section vma first).  The second commit limited the
warning to ET_REL where st_value is a section offset and thus can be
compared directly to the section size.
binutils/readelf.c