Commit: Fix merging empty ppc64le notes
Nick Clifton
nickc@redhat.com
Thu Feb 18 11:43:14 GMT 2021
Hi Guys,
I am applying the patch below to fix a problem merging empty PowerPC
annobin notes, which can have a start address higher than the end
address.
Cheers
Nick
binutils/ChangeLog
2021-02-18 Nick Clifton <nickc@redhat.com>
* objcopy.c (merge_gnu_build_notes): Handle notes with a start
address that is higher than the end address.
diff --git a/binutils/objcopy.c b/binutils/objcopy.c
index 0e1047e748..54a59430f1 100644
--- a/binutils/objcopy.c
+++ b/binutils/objcopy.c
@@ -2275,6 +2275,11 @@ merge_gnu_build_notes (bfd * abfd,
goto done;
}
+ if (start > end)
+ /* This can happen with PPC64LE binaries where empty notes are
+ encoded as start = end + 4. */
+ start = end;
+
if (is_open_note (pnote))
{
if (start)
More information about the Binutils
mailing list