diff options
Diffstat (limited to 'bfd/coff-w65.c')
-rw-r--r-- | bfd/coff-w65.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/bfd/coff-w65.c b/bfd/coff-w65.c index 3119ad6..7a1cfb7 100644 --- a/bfd/coff-w65.c +++ b/bfd/coff-w65.c @@ -1,5 +1,5 @@ /* BFD back-end for WDC 65816 COFF binaries. - Copyright 1995, 1996, 1997, 1999, 2000, 2001, 2002, 2003, 2004 + Copyright 1995, 1996, 1997, 1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. Written by Steve Chamberlain, <sac@cygnus.com>. @@ -316,9 +316,9 @@ w65_reloc16_extra_cases (abfd, link_info, link_order, reloc, data, src_ptr, { int gap = bfd_coff_reloc16_get_value (reloc, link_info, input_section); - bfd_vma dot = link_order->offset - + dst_address - + link_order->u.indirect.section->output_section->vma; + bfd_vma dot = (dst_address + + input_section->output_offset + + input_section->output_section->vma); gap -= dot + 1; if (gap < -128 || gap > 127) @@ -340,9 +340,9 @@ w65_reloc16_extra_cases (abfd, link_info, link_order, reloc, data, src_ptr, { bfd_vma gap = bfd_coff_reloc16_get_value (reloc, link_info, input_section); - bfd_vma dot = link_order->offset - + dst_address - + link_order->u.indirect.section->output_section->vma; + bfd_vma dot = (dst_address + + input_section->output_offset + + input_section->output_section->vma); /* This wraps within the page, so ignore the relativeness, look at the high part. */ |