[binutils-gdb] ft32: return false from relax_section error path
Jan Beulich
jbeulich@sourceware.org
Fri Nov 13 13:26:08 GMT 2026
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=086fb65bdbe60b4e443d35dc8d772567207d469f
commit 086fb65bdbe60b4e443d35dc8d772567207d469f
Author: Harshit Kumar <harshit7kr@gmail.com>
Date: Fri Nov 13 14:23:46 2026 +0100
ft32: return false from relax_section error path
In ft32_elf_relax_section, the error_return: block returned true, so
failures to read the section contents, local symbols or relocations,
and failures from elf32_ft32_relax_delete_bytes, were reported as
success and relaxation continued with corrupt state. Correct
error_return: to return false.
Signed-off-by: Harshit Kumar <harshit7kr@gmail.com>
Diff:
---
bfd/elf32-ft32.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/bfd/elf32-ft32.c b/bfd/elf32-ft32.c
index 3e4e6f3988b..50aa8a89b6e 100644
--- a/bfd/elf32-ft32.c
+++ b/bfd/elf32-ft32.c
@@ -1237,7 +1237,7 @@ ft32_elf_relax_section (bfd *abfd,
error_return:
free (free_relocs);
- return true;
+ return false;
}
#define ELF_ARCH bfd_arch_ft32
More information about the Binutils-cvs
mailing list