diff options
author | Alan Modra <amodra@gmail.com> | 2020-12-07 14:03:47 +1030 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2020-12-07 22:17:05 +1030 |
commit | fde0214a915dc09743006022df2365f8e9ea3eed (patch) | |
tree | 79c664a764b545c935133430c6bc610afffd2d4c /bfd/elf32-nds32.c | |
parent | a315d3902d6aa485c385f0b977da71cd7c3adb38 (diff) | |
download | gdb-fde0214a915dc09743006022df2365f8e9ea3eed.zip gdb-fde0214a915dc09743006022df2365f8e9ea3eed.tar.gz gdb-fde0214a915dc09743006022df2365f8e9ea3eed.tar.bz2 |
elf32-csky.c:3932:19: error: comparison is always false
It looks like csky missed out on an edit for 706704c8834. Not that it
matters very much. There doesn't appear to be any csky reloc howto
that sets the negate bit.
Similarly for ns32k and nds32.
* elf32-csky.c (csky_relocate_contents): Correct negate test.
* cpu-ns32k.c (_bfd_do_ns32k_reloc_contents): Likewise.
* elf32-nds32.c (nds32_relocate_contents): Likewise.
Diffstat (limited to 'bfd/elf32-nds32.c')
-rw-r--r-- | bfd/elf32-nds32.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/bfd/elf32-nds32.c b/bfd/elf32-nds32.c index 233af38..105d7f5 100644 --- a/bfd/elf32-nds32.c +++ b/bfd/elf32-nds32.c @@ -4492,9 +4492,7 @@ nds32_relocate_contents (reloc_howto_type *howto, bfd *input_bfd, unsigned int rightshift = howto->rightshift; unsigned int bitpos = howto->bitpos; - /* If the size is negative, negate RELOCATION. This isn't very - general. */ - if (howto->size < 0) + if (howto->negate) relocation = -relocation; /* Get the value we are going to relocate. */ |