aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf64-sparc.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/elf64-sparc.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/elf64-sparc.c')
-rw-r--r--bfd/elf64-sparc.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/bfd/elf64-sparc.c b/bfd/elf64-sparc.c
index 184179e..ae4e57a 100644
--- a/bfd/elf64-sparc.c
+++ b/bfd/elf64-sparc.c
@@ -2584,11 +2584,10 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
/* The Solaris native linker silently disregards
overflows. We don't, but this breaks stabs debugging
info, whose relocations are only 32-bits wide. Ignore
- overflows in this case. */
+ overflows for discarded entries. */
if (r_type == R_SPARC_32
- && (input_section->flags & SEC_DEBUGGING) != 0
- && strcmp (bfd_section_name (input_bfd, input_section),
- ".stab") == 0)
+ && _bfd_elf_section_offset (output_bfd, info, input_section,
+ rel->r_offset) == (bfd_vma) -1)
break;
if (h != NULL)