diff options
author | Alan Modra <amodra@gmail.com> | 2022-07-04 11:24:22 +0930 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2022-07-04 22:51:56 +0930 |
commit | 0772daccb3ebaf513badf4266e1948454b4455c1 (patch) | |
tree | 23032d204a77ac8f9c8cec3a0c48e0ee8b826548 /makefile.vms | |
parent | d8efadbdd94772562fed8fba9ce553587a62550f (diff) | |
download | gdb-0772daccb3ebaf513badf4266e1948454b4455c1.zip gdb-0772daccb3ebaf513badf4266e1948454b4455c1.tar.gz gdb-0772daccb3ebaf513badf4266e1948454b4455c1.tar.bz2 |
objcopy: bfd_alloc orelocation
This fixes an inconsequential objcopy memory leak. I'd normally
ignore reports of leaks like this one, that are merely one block or
fewer per section processed, since objcopy soon exits and frees all
memory. However I thought it worth providing support for allocating
memory on a bfd objalloc in objcopy and other utils.
PR 29233
* bucomm.c (bfd_xalloc): New function.
* bucomm.h (bfd_xalloc): Declare.
* objcopy.c (copy_relocations_in_section): Use it to allocate
array of reloc pointers. Rewrite code stripping relocs to do
without extra memory allocation.
Diffstat (limited to 'makefile.vms')
0 files changed, 0 insertions, 0 deletions