From: Alan Modra Date: Thu, 2 Jun 2022 07:13:48 +0000 (+0930) Subject: asan: uninit write _bfd_ecoff_write_object_contents X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ee6cbff21381025f988457d9481d5b3b8d05bb72;p=binutils-gdb.git asan: uninit write _bfd_ecoff_write_object_contents * ecoff.c (_bfd_ecoff_write_object_contents): zalloc reloc_buff. --- diff --git a/bfd/ecoff.c b/bfd/ecoff.c index d2081055835..511d88b5339 100644 --- a/bfd/ecoff.c +++ b/bfd/ecoff.c @@ -2632,7 +2632,7 @@ _bfd_ecoff_write_object_contents (bfd *abfd) continue; amt = current->reloc_count * external_reloc_size; - reloc_buff = bfd_alloc (abfd, amt); + reloc_buff = bfd_zalloc (abfd, amt); if (reloc_buff == NULL) goto error_return;