From d5827a0e838caacb0337be95e6661fd8281e1968 Mon Sep 17 00:00:00 2001 From: Jan Beulich Date: Fri, 27 Dec 2024 11:37:42 +0100 Subject: [PATCH] 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. --- 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); } } -- 2.47.2