diff options
author | Alan Modra <amodra@gmail.com> | 2023-12-05 09:23:41 +1030 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2023-12-06 12:23:05 +1030 |
commit | 3c8852fcc806915fdeab8b3d6f49be7347160527 (patch) | |
tree | 0738b9341e04fae97c7cc25efa39f86e054e99ca /gdbsupport | |
parent | 9d498f4286d7058f448cf78214c0bc6cdf8dad31 (diff) | |
download | binutils-3c8852fcc806915fdeab8b3d6f49be7347160527.zip binutils-3c8852fcc806915fdeab8b3d6f49be7347160527.tar.gz binutils-3c8852fcc806915fdeab8b3d6f49be7347160527.tar.bz2 |
PR31096, nm shows 32bit addresses as 64bit addresses
Prior to commit 0e3c1eebb2 nm output depended on the host unsigned
long when printing "negative" symbol values for 32-bit targets.
Commit 0e3c1eebb22 made the output match that seen with a 64-bit host
unsigned long. The fact that nm output changed depending on host is
of course a bug, but it is reasonable to expect 32-bit target output
is only 32 bits. So this patch makes 32-bit target output the same as
it was on 32-bit hosts prior to 0e3c1eebb2.
PR 31096
* nm.c (print_format_string): Make it a static buffer.
(get_print_format): Merge into..
(set_print_format): ..this, renamed from set_print_width. When
print_width is 32, set up print_format_string for an int32_t
value. Don't malloc print_format_string. Adjust calls.
(print_value): Correct printing of 32-bit values.
Diffstat (limited to 'gdbsupport')
0 files changed, 0 insertions, 0 deletions