readelf display of 0x800...000 addend
* readelf.c (dump_relocations): Show MIN_INT addends as negative.
This commit is contained in:
parent
511b1657d2
commit
7360e63f80
2 changed files with 8 additions and 10 deletions
|
@ -1,3 +1,7 @@
|
||||||
|
2015-07-22 Alan Modra <amodra@gmail.com>
|
||||||
|
|
||||||
|
* readelf.c (dump_relocations): Show MIN_INT addends as negative.
|
||||||
|
|
||||||
2015-07-20 Alan Modra <amodra@gmail.com>
|
2015-07-20 Alan Modra <amodra@gmail.com>
|
||||||
|
|
||||||
* doc/Makefile.in: Regenerate.
|
* doc/Makefile.in: Regenerate.
|
||||||
|
|
|
@ -1608,12 +1608,9 @@ dump_relocations (FILE * file,
|
||||||
|
|
||||||
if (is_rela)
|
if (is_rela)
|
||||||
{
|
{
|
||||||
bfd_signed_vma off = rels[i].r_addend;
|
bfd_vma off = rels[i].r_addend;
|
||||||
|
|
||||||
/* PR 17531: file: 2e63226f. */
|
if ((bfd_signed_vma) off < 0)
|
||||||
if (off == ((bfd_signed_vma) 1) << ((sizeof (bfd_signed_vma) * 8) - 1))
|
|
||||||
printf (" + %" BFD_VMA_FMT "x", off);
|
|
||||||
else if (off < 0)
|
|
||||||
printf (" - %" BFD_VMA_FMT "x", - off);
|
printf (" - %" BFD_VMA_FMT "x", - off);
|
||||||
else
|
else
|
||||||
printf (" + %" BFD_VMA_FMT "x", off);
|
printf (" + %" BFD_VMA_FMT "x", off);
|
||||||
|
@ -1622,13 +1619,10 @@ dump_relocations (FILE * file,
|
||||||
}
|
}
|
||||||
else if (is_rela)
|
else if (is_rela)
|
||||||
{
|
{
|
||||||
bfd_signed_vma off = rels[i].r_addend;
|
bfd_vma off = rels[i].r_addend;
|
||||||
|
|
||||||
printf ("%*c", is_32bit_elf ? 12 : 20, ' ');
|
printf ("%*c", is_32bit_elf ? 12 : 20, ' ');
|
||||||
/* PR 17531: file: 2e63226f. */
|
if ((bfd_signed_vma) off < 0)
|
||||||
if (off == ((bfd_signed_vma) 1) << ((sizeof (bfd_signed_vma) * 8) - 1))
|
|
||||||
printf ("%" BFD_VMA_FMT "x", off);
|
|
||||||
else if (off < 0)
|
|
||||||
printf ("-%" BFD_VMA_FMT "x", - off);
|
printf ("-%" BFD_VMA_FMT "x", - off);
|
||||||
else
|
else
|
||||||
printf ("%" BFD_VMA_FMT "x", off);
|
printf ("%" BFD_VMA_FMT "x", off);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue