diff options
Diffstat (limited to 'bfd/elf32-cris.c')
-rw-r--r-- | bfd/elf32-cris.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/bfd/elf32-cris.c b/bfd/elf32-cris.c index c588adc..ef8c951 100644 --- a/bfd/elf32-cris.c +++ b/bfd/elf32-cris.c @@ -1296,20 +1296,20 @@ cris_elf_relocate_section (output_bfd, info, input_bfd, input_section, } skip = false; + relocate = false; outrel.r_offset = _bfd_elf_section_offset (output_bfd, info, input_section, rel->r_offset); if (outrel.r_offset == (bfd_vma) -1) skip = true; + else if (outrel.r_offset == (bfd_vma) -2) + skip = true, relocate = true; outrel.r_offset += (input_section->output_section->vma + input_section->output_offset); if (skip) - { - memset (&outrel, 0, sizeof outrel); - relocate = false; - } + memset (&outrel, 0, sizeof outrel); /* h->dynindx may be -1 if the symbol was marked to become local. */ else if (h != NULL @@ -1318,7 +1318,6 @@ cris_elf_relocate_section (output_bfd, info, input_bfd, input_section, & ELF_LINK_HASH_DEF_REGULAR) == 0)) { BFD_ASSERT (h->dynindx != -1); - relocate = false; outrel.r_info = ELF32_R_INFO (h->dynindx, r_type); outrel.r_addend = relocation + rel->r_addend; } @@ -1359,7 +1358,6 @@ cris_elf_relocate_section (output_bfd, info, input_bfd, input_section, BFD_ASSERT (indx > 0); } - relocate = false; outrel.r_info = ELF32_R_INFO (indx, r_type); outrel.r_addend = relocation + rel->r_addend; } |