FreeBSD/contrib/binutils/bfd/elflink.c
/* Flush the output symbols to the file.  */
Flush the output symbols to the file.
Flush the output symbols to the file .
static bfd_boolean
elf_link_flush_output_syms (struct elf_final_link_info *finfo,
			    const struct elf_backend_data *bed)
{
  if (finfo->symbuf_count > 0)
    {
      Elf_Internal_Shdr *hdr;
      file_ptr pos;
      bfd_size_type amt;
      hdr = &elf_tdata (finfo->output_bfd)->symtab_hdr;
      pos = hdr->sh_offset + hdr->sh_size;
      amt = finfo->symbuf_count * bed->s->sizeof_sym;
      if (bfd_seek (finfo->output_bfd, pos, SEEK_SET) != 0
	  || bfd_bwrite (finfo->symbuf, amt, finfo->output_bfd) != amt)
	return FALSE;
      hdr->sh_size += amt;
      finfo->symbuf_count = 0;
    }
  return TRUE;
}
static bfd_boolean elf_link_flush_output_syms ( struct elf_final_link_info * finfo , const struct elf_backend_data * bed ) { if ( finfo -> symbuf_count > 0 ) { Elf_Internal_Shdr * hdr ; file_ptr pos ; bfd_size_type amt ; hdr = & elf_tdata ( finfo -> output_bfd ) -> symtab_hdr ; pos = hdr -> sh_offset + hdr -> sh_size ; amt = finfo -> symbuf_count * bed -> s -> sizeof_sym ; if ( bfd_seek ( finfo -> output_bfd , pos , SEEK_SET ) != 0 || bfd_bwrite ( finfo -> symbuf , amt , finfo -> output_bfd ) != amt ) return FALSE ; hdr -> sh_size += amt ; finfo -> symbuf_count = 0 ; } return TRUE ; }
Flush the output symbols to the file.
Flush the output symbols to the file .