[binutils-gdb] bfd/ELF: refine segment index in filepos assignment diag
Jan Beulich
jbeulich@sourceware.org
Fri Dec 27 10:38:30 GMT 2024
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=d5827a0e838caacb0337be95e6661fd8281e1968
commit d5827a0e838caacb0337be95e6661fd8281e1968
Author: Jan Beulich <jbeulich@suse.com>
Date: Fri Dec 27 11:37:42 2024 +0100
bfd/ELF: refine segment index in filepos assignment diag
Reporting an internal loop index isn't helpful for the user to determine
which segment the problem is with. Report the PHDR index instead.
Diff:
---
bfd/elf.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/bfd/elf.c b/bfd/elf.c
index 9f5ac6384f3..4b8efeb49ca 100644
--- a/bfd/elf.c
+++ b/bfd/elf.c
@@ -6398,8 +6398,8 @@ assign_file_positions_for_load_sections (bfd *abfd,
{
_bfd_error_handler
/* xgettext:c-format */
- (_("%pB: section `%pA' can't be allocated in segment %d"),
- abfd, sec, j);
+ (_("%pB: section `%pA' can't be allocated in segment %u"),
+ abfd, sec, m->idx);
print_segment_map (m);
}
}
More information about the Binutils-cvs
mailing list