mirror of
https://github.com/darlinghq/darling-gdb.git
synced 2024-11-24 20:49:43 +00:00
2006-09-26 H.J. Lu <hongjiu.lu@intel.com>
PR binutils/3262 * elf.c (rewrite_elf_program_header): Use bfd_zalloc instead of bfd_alloc to allocate segment map. (copy_elf_program_header): Likewise.
This commit is contained in:
parent
030cbcedf2
commit
41f8ce693c
@ -1,3 +1,10 @@
|
||||
2006-09-26 H.J. Lu <hongjiu.lu@intel.com>
|
||||
|
||||
PR binutils/3262
|
||||
* elf.c (rewrite_elf_program_header): Use bfd_zalloc instead of
|
||||
bfd_alloc to allocate segment map.
|
||||
(copy_elf_program_header): Likewise.
|
||||
|
||||
2006-09-26 Mark Shinwell <shinwell@codesourcery.com>
|
||||
Joseph Myers <joseph@codesourcery.com>
|
||||
Ian Lance Taylor <ian@wasabisystems.com>
|
||||
|
@ -5401,7 +5401,7 @@ rewrite_elf_program_header (bfd *ibfd, bfd *obfd)
|
||||
all of the sections we have selected. */
|
||||
amt = sizeof (struct elf_segment_map);
|
||||
amt += ((bfd_size_type) section_count - 1) * sizeof (asection *);
|
||||
map = bfd_alloc (obfd, amt);
|
||||
map = bfd_zalloc (obfd, amt);
|
||||
if (map == NULL)
|
||||
return FALSE;
|
||||
|
||||
@ -5796,7 +5796,7 @@ copy_elf_program_header (bfd *ibfd, bfd *obfd)
|
||||
amt = sizeof (struct elf_segment_map);
|
||||
if (section_count != 0)
|
||||
amt += ((bfd_size_type) section_count - 1) * sizeof (asection *);
|
||||
map = bfd_alloc (obfd, amt);
|
||||
map = bfd_zalloc (obfd, amt);
|
||||
if (map == NULL)
|
||||
return FALSE;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user