From: Doug Evans Date: Mon, 6 May 2013 18:50:08 +0000 (+0000) Subject: * symfile.c (syms_from_objfile_1): Use correct section count when X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=a7bfba49b274e06c468abeff7ca92156c0d72293;p=binutils-gdb.git * symfile.c (syms_from_objfile_1): Use correct section count when objfile->sf == NULL. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 25962917a10..43a502a0153 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2013-05-06 Doug Evans + + * symfile.c (syms_from_objfile_1): Use correct section count when + objfile->sf == NULL. + 2013-05-06 Mike Frysinger * common/linux-btrace.c (intel_supports_btrace): Fix indentation. diff --git a/gdb/symfile.c b/gdb/symfile.c index 13740df0ea1..48d5f73131b 100644 --- a/gdb/symfile.c +++ b/gdb/symfile.c @@ -949,7 +949,7 @@ syms_from_objfile_1 (struct objfile *objfile, /* No symbols to load, but we still need to make sure that the section_offsets table is allocated. */ int num_sections = gdb_bfd_count_sections (objfile->obfd); - size_t size = SIZEOF_N_SECTION_OFFSETS (num_offsets); + size_t size = SIZEOF_N_SECTION_OFFSETS (num_sections); objfile->num_sections = num_sections; objfile->section_offsets