From d79dcc73ac46dad924acf843a2c3546517506f9e Mon Sep 17 00:00:00 2001 From: Nick Clifton Date: Fri, 25 Jan 2013 14:22:10 +0000 Subject: * elf32-h8300.c (elf32_h8_relax_section): When checking for a second reloc, make sure that the reloc potentially exists first. --- bfd/elf32-h8300.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'bfd/elf32-h8300.c') diff --git a/bfd/elf32-h8300.c b/bfd/elf32-h8300.c index 388d220..43ac16e 100644 --- a/bfd/elf32-h8300.c +++ b/bfd/elf32-h8300.c @@ -1239,7 +1239,7 @@ elf32_h8_relax_section (bfd *abfd, asection *sec, second_reloc = 1; } } - if (irel < irelend) + if (irel + 1 < irelend) { Elf_Internal_Rela *next_reloc = irel + 1; arelent bfd_reloc; -- cgit v1.1