This is the mail archive of the
binutils-cvs@sourceware.org
mailing list for the binutils project.
[binutils-gdb] Fix compile time warning: bfd/elf32-arc.c:1537]: (warning) Redundant assignment of 'rel->r_offset' t
- From: Nick Clifton <nickc at sourceware dot org>
- To: bfd-cvs at sourceware dot org
- Date: 12 Feb 2018 11:58:44 -0000
- Subject: [binutils-gdb] Fix compile time warning: bfd/elf32-arc.c:1537]: (warning) Redundant assignment of 'rel->r_offset' t
https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=0b8683b7eb25cc150c7738ddc0d237f255e0fa70
commit 0b8683b7eb25cc150c7738ddc0d237f255e0fa70
Author: Nick Clifton <nickc@redhat.com>
Date: Mon Feb 12 11:57:41 2018 +0000
Fix compile time warning: bfd/elf32-arc.c:1537]: (warning) Redundant assignment of 'rel->r_offset' to itself.
* elf32-arc.c (elf_arc_relocate_section): Remove redundant
assignment.
Diff:
---
bfd/ChangeLog | 1 +
bfd/elf32-arc.c | 1 -
2 files changed, 1 insertion(+), 1 deletion(-)
diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index 5f7fcf3..f147806 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -2,6 +2,7 @@
* elf32-nds32.c (nds32_elf_relax_longjump3): Remove redundant
assignment.
+ * elf32-arc.c (elf_arc_relocate_section): Likewise.
2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
diff --git a/bfd/elf32-arc.c b/bfd/elf32-arc.c
index 5921cc2..1ad9e3e 100644
--- a/bfd/elf32-arc.c
+++ b/bfd/elf32-arc.c
@@ -1534,7 +1534,6 @@ elf_arc_relocate_section (bfd * output_bfd,
{
_bfd_clear_contents (howto, input_bfd, input_section,
contents + rel->r_offset);
- rel->r_offset = rel->r_offset;
rel->r_info = 0;
rel->r_addend = 0;