* objcopy.c (copy_section): Use bfd_get_section_size instead of

_raw_size or bfd_get_section_size_before_reloc.  Don't set reloc_done.
	(compare_section_lma): Likewise.
	* addr2line.c (find_address_in_section): Likewise.
	* coffgrok.c (do_sections_p1): Likewise.
	* dlltool.c (scan_drectve_symbols): Likewise.
	* nlmconv.c (main): Likewise.
	(copy_sections): Likewise.
	(powerpc_mangle_relocs): Likewise.
	* objdump.c (disassemble_section): Likewise.
	* prdbg.c (find_address_in_section): Likewise.
	* size.c (berkeley_sum): Likewise.
	* srconv.c (wr_ob): Likewise.
	* strings.c (strings_a_section): Likewise.
This commit is contained in:
Alan Modra 2004-06-15 01:19:13 +00:00
parent 587aac4eaf
commit 135dfb4a65
11 changed files with 47 additions and 36 deletions

View file

@ -2014,7 +2014,7 @@ copy_section (bfd *ibfd, sec_ptr isection, void *obfdarg)
return;
osection = isection->output_section;
size = bfd_get_section_size_before_reloc (isection);
size = bfd_get_section_size (isection);
if (size == 0 || osection == 0)
return;
@ -2071,7 +2071,6 @@ copy_section (bfd *ibfd, sec_ptr isection, void *obfdarg)
}
isection->_cooked_size = isection->_raw_size;
isection->reloc_done = TRUE;
if (bfd_get_section_flags (ibfd, isection) & SEC_HAS_CONTENTS
&& bfd_get_section_flags (obfd, osection) & SEC_HAS_CONTENTS)
@ -2164,9 +2163,9 @@ compare_section_lma (const void *arg1, const void *arg2)
return -1;
/* Sort sections with the same LMA by size. */
if ((*sec1)->_raw_size > (*sec2)->_raw_size)
if (bfd_get_section_size (*sec1) > bfd_get_section_size (*sec2))
return 1;
else if ((*sec1)->_raw_size < (*sec2)->_raw_size)
else if (bfd_get_section_size (*sec1) < bfd_get_section_size (*sec2))
return -1;
return 0;