* xcofflink.c (_bfd_xcoff_bfd_final_link): Call bfd_malloc rather

than malloc.
This commit is contained in:
Ian Lance Taylor 1997-03-18 17:58:48 +00:00
parent 724a4c0d46
commit 939b216956
2 changed files with 7 additions and 5 deletions

View File

@ -1,3 +1,8 @@
Tue Mar 18 12:58:08 1997 Ian Lance Taylor <ian@cygnus.com>
* xcofflink.c (_bfd_xcoff_bfd_final_link): Call bfd_malloc rather
than malloc.
Mon Mar 17 11:32:53 1997 Ian Lance Taylor <ian@cygnus.com> Mon Mar 17 11:32:53 1997 Ian Lance Taylor <ian@cygnus.com>
* bfd-in.h: Don't include obstack.h. * bfd-in.h: Don't include obstack.h.

View File

@ -4185,12 +4185,9 @@ _bfd_xcoff_bfd_final_link (abfd, info)
/* Now that we have written out all the global symbols, we know the /* Now that we have written out all the global symbols, we know the
symbol indices to use for relocs against them, and we can finally symbol indices to use for relocs against them, and we can finally
write out the relocs. */ write out the relocs. */
external_relocs = (bfd_byte *) malloc (max_output_reloc_count * relsz); external_relocs = (bfd_byte *) bfd_malloc (max_output_reloc_count * relsz);
if (external_relocs == NULL && max_output_reloc_count != 0) if (external_relocs == NULL && max_output_reloc_count != 0)
{ goto error_return;
bfd_set_error (bfd_error_no_memory);
goto error_return;
}
for (o = abfd->sections; o != NULL; o = o->next) for (o = abfd->sections; o != NULL; o = o->next)
{ {