From: Eric B. Weddington Date: Thu, 19 Feb 2009 17:53:10 +0000 (+0000) Subject: /bfd: X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=5b4e2e256ff05f3023bf4aca9afa93e126daec9e;p=thirdparty%2Fbinutils-gdb.git /bfd: 2009-02-15 Bjoern Haase PR 9841 * elf32-avr.c: Handle case where no local symbos exist correctly. --- diff --git a/bfd/ChangeLog b/bfd/ChangeLog index 47e70c45e3c..e925156ea84 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,8 @@ +2009-02-15 Bjoern Haase + + PR 9841 + * elf32-avr.c: Handle case where no local symbos exist correctly. + 2009-02-04 Eric B. Weddington * elf32-avr.c (avr_final_link_relocate): Allow avr25 to wraparound. diff --git a/bfd/elf32-avr.c b/bfd/elf32-avr.c index afcef18aa30..27cb38b8644 100644 --- a/bfd/elf32-avr.c +++ b/bfd/elf32-avr.c @@ -1554,7 +1554,8 @@ elf32_avr_relax_delete_bytes (bfd *abfd, /* Adjust the local symbols defined in this section. */ isym = (Elf_Internal_Sym *) symtab_hdr->contents; isymend = isym + symtab_hdr->sh_info; - for (; isym < isymend; isym++) + /* Fix PR 9841, there may be no local symbols. */ + for (; isym != NULL && isym < isymend; isym++) { if (isym->st_shndx == sec_shndx && isym->st_value > addr