aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf64-sparc.c
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2001-05-23 08:23:27 +0000
committerNick Clifton <nickc@redhat.com>2001-05-23 08:23:27 +0000
commitd9bc7a4499c25b26971d80e2392a6da6e84cbe21 (patch)
tree1aaf6ffea75c9c46b0a162c38d9fec15951869a2 /bfd/elf64-sparc.c
parent60edd2d3f1f08fff5dc35137a16c5ec4eaa8392e (diff)
downloadgdb-d9bc7a4499c25b26971d80e2392a6da6e84cbe21.zip
gdb-d9bc7a4499c25b26971d80e2392a6da6e84cbe21.tar.gz
gdb-d9bc7a4499c25b26971d80e2392a6da6e84cbe21.tar.bz2
Replace sh_size/sh_entsize with NUM_SHDR_ENTRIES
Diffstat (limited to 'bfd/elf64-sparc.c')
-rw-r--r--bfd/elf64-sparc.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/bfd/elf64-sparc.c b/bfd/elf64-sparc.c
index dc393b3..295bd2f 100644
--- a/bfd/elf64-sparc.c
+++ b/bfd/elf64-sparc.c
@@ -396,7 +396,7 @@ sparc64_elf_slurp_reloc_table (abfd, asect, symbols, dynamic)
return true;
rel_hdr = &d->this_hdr;
- asect->reloc_count = rel_hdr->sh_size / rel_hdr->sh_entsize;
+ asect->reloc_count = NUM_SHDR_ENTRIES (rel_hdr);
rel_hdr2 = NULL;
}
@@ -996,8 +996,7 @@ sparc64_elf_check_relocs (abfd, info, sec, relocs)
srelgot = NULL;
sreloc = NULL;
- rel_end = relocs + elf_section_data (sec)->rel_hdr.sh_size
- / elf_section_data (sec)->rel_hdr.sh_entsize;
+ rel_end = relocs + NUM_SHDR_ENTRIES (& elf_section_data (sec)->rel_hdr);
for (rel = relocs; rel < rel_end; rel++)
{
unsigned long r_symndx;
@@ -1903,8 +1902,7 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
sgot = splt = sreloc = NULL;
rel = relocs;
- relend = relocs + elf_section_data (input_section)->rel_hdr.sh_size
- / elf_section_data (input_section)->rel_hdr.sh_entsize;
+ relend = relocs + NUM_SHDR_ENTIRES (& elf_section_data (input_section)->rel_hdr);
for (; rel < relend; rel++)
{
int r_type;