aboutsummaryrefslogtreecommitdiff
path: root/bfd/elf32-m68k.c
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>1997-06-16 18:45:30 +0000
committerIan Lance Taylor <ian@airs.com>1997-06-16 18:45:30 +0000
commitfdc944a7fbc28c1050c108ea4dac6e1a7a3fb173 (patch)
tree03a99255318a5c5b4a5f6e9e594c5a27c0bd9b4a /bfd/elf32-m68k.c
parentc19fbe0f575f18abe9fefb471cbd2d6d3bc9ed09 (diff)
downloadgdb-fdc944a7fbc28c1050c108ea4dac6e1a7a3fb173.zip
gdb-fdc944a7fbc28c1050c108ea4dac6e1a7a3fb173.tar.gz
gdb-fdc944a7fbc28c1050c108ea4dac6e1a7a3fb173.tar.bz2
Mon Jun 16 14:42:14 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
* elfcode.h (put_signed_word): Define. (get_signed_word): Define. (elf_swap_reloca_in): Use get_signed_word for the r_addend field. (elf_swap_reloca_out): Use put_signed_word for the r_addend field. * elf32-m68k.c (elf_m68k_finish_dynamic_symbol): Use bfd_get_signed_32 to set the r_addend field. * elf64-mips.c (mips_elf64_swap_reloca_in): Use bfd_h_get_signed_64 to set the r_addend field.
Diffstat (limited to 'bfd/elf32-m68k.c')
-rw-r--r--bfd/elf32-m68k.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/bfd/elf32-m68k.c b/bfd/elf32-m68k.c
index 1d763a9..4ba4282 100644
--- a/bfd/elf32-m68k.c
+++ b/bfd/elf32-m68k.c
@@ -1626,8 +1626,9 @@ elf_m68k_finish_dynamic_symbol (output_bfd, info, h, sym)
&& (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR))
{
rela.r_info = ELF32_R_INFO (0, R_68K_RELATIVE);
- rela.r_addend = bfd_get_32 (output_bfd,
- sgot->contents + (h->got_offset & ~1));
+ rela.r_addend = bfd_get_signed_32 (output_bfd,
+ (sgot->contents
+ + (h->got_offset & ~1)));
}
else
{