aboutsummaryrefslogtreecommitdiff
path: root/bfd/elfxx-ia64.c
diff options
context:
space:
mode:
authorAlan Modra <amodra@gmail.com>2002-11-12 06:21:05 +0000
committerAlan Modra <amodra@gmail.com>2002-11-12 06:21:05 +0000
commit99eb2ac83dc99f32cf4eec92071756c3aaf6582c (patch)
treeb301cc577f03f7b037d2a0b309196a054c390c9e /bfd/elfxx-ia64.c
parent852f55ac64a8aacd9bcfd59a044041db2919c563 (diff)
downloadgdb-99eb2ac83dc99f32cf4eec92071756c3aaf6582c.zip
gdb-99eb2ac83dc99f32cf4eec92071756c3aaf6582c.tar.gz
gdb-99eb2ac83dc99f32cf4eec92071756c3aaf6582c.tar.bz2
* elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't zero
relocs for discarded FDEs. Remove dead code. (_bfd_elf_write_section_eh_frame_hdr): Remove dead code. * elflink.h (elf_bfd_discard_info): Don't save edited relocs. Tidy conditions under which stabs are edited. Formatting. * elf64-sparc.c (sparc64_elf_relocate_section): Ignore overflows from discarded relocs. * elfxx-ia64.c (elfNN_ia64_install_dyn_reloc): Add reloc output section adjustments after testing magic values.
Diffstat (limited to 'bfd/elfxx-ia64.c')
-rw-r--r--bfd/elfxx-ia64.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/bfd/elfxx-ia64.c b/bfd/elfxx-ia64.c
index 5da8e43..ddd86fb 100644
--- a/bfd/elfxx-ia64.c
+++ b/bfd/elfxx-ia64.c
@@ -3204,13 +3204,11 @@ elfNN_ia64_install_dyn_reloc (abfd, info, sec, srel, offset, type,
{
Elf_Internal_Rela outrel;
- offset += sec->output_section->vma + sec->output_offset;
-
BFD_ASSERT (dynindx != -1);
outrel.r_info = ELFNN_R_INFO (dynindx, type);
outrel.r_addend = addend;
outrel.r_offset = _bfd_elf_section_offset (abfd, info, sec, offset);
- if ((outrel.r_offset | 1) == (bfd_vma) -1)
+ if (outrel.r_offset >= (bfd_vma) -2)
{
/* Run for the hills. We shouldn't be outputting a relocation
for this. So do what everyone else does and output a no-op. */
@@ -3218,6 +3216,8 @@ elfNN_ia64_install_dyn_reloc (abfd, info, sec, srel, offset, type,
outrel.r_addend = 0;
outrel.r_offset = 0;
}
+ else
+ outrel.r_offset += sec->output_section->vma + sec->output_offset;
bfd_elfNN_swap_reloca_out (abfd, &outrel,
((ElfNN_External_Rela *) srel->contents