https://sourceware.org/bugzilla/show_bug.cgi?id=31097
Aaron Merey <amerey at redhat dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Status|NEW |RESOLVED --- Comment #1 from Aaron Merey <amerey at redhat dot com> --- Fixed in the following commit: commit 2f9b180cc1057fb351332689886b2492b3711aad Author: Aaron Merey <ame...@redhat.com> Date: Sun Jan 21 19:44:34 2024 -0500 unstrip: Call adjust_relocs no more than once per section. During symtab merging, adjust_relocs might be called multiple times on some SHT_REL/SHT_RELA sections. In these cases it is possible for a relocation's symbol index to be correctly mapped from X to Y during the first call to adjust_relocs but then wrongly remapped from Y to Z during the second call. Fix this by adjusting relocation symbol indices just once per section. Also add stable sorting for symbols during symtab merging so that the symbol order in the output file's symtab does not depend on undefined behaviour in qsort. Note that adjust_relocs still might be called a second time on a section during add_new_section_symbols. However since add_new_section_symbols generates its own distinct symbol index map, this should not trigger the bug described above. -- You are receiving this mail because: You are on the CC list for the bug.