Move modification of bfd abs and und back to gas
Alan Modra
amodra@gmail.com
Mon Dec 16 11:09:59 GMT 2024
On Mon, Dec 16, 2024 at 10:04:52AM +1030, Alan Modra wrote:
> The same thing could happen if a user runs objdump or nm with two
> files on the command line, the first being a tekhex file with absolute
> symbols, or if ld is given tekhex input among other files. Clearly,
> it's a bad idea to modify the *ABS* or *UND* sections for input files.
FWIW, I managed to create a reproducer from one of the oss-fuzz
testcases.
printf '\0' > bin
binutils/objcopy -I binary -O tekhex bin tekhex
printf '\144\252\002\000\377\133\100\377\002\000\000\000\002\000\000\000\000\000\020\000\056\144\167\146\162\141\155\145\000\000\000\000\000\000\000\000\006\000\000\000\200\000\000\000\074\000\000\000\000\000\000\350\003\000\000\000\000\000\040\020\000\000\000\000\000\334\000\363\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\000\040\040\040\040\040\040\040\040\040\040\040\377\040\000\000\377\000\100\377\002\000\000\000\002\000\000\000\000\000\020\000\056\144\167\000\000\000\000\000' > peaarch64
binutils/objdump -W tekhex peaarch64
--
Alan Modra
More information about the Binutils
mailing list