From: Elena Zannoni Date: Thu, 14 Aug 2003 20:12:31 +0000 (+0000) Subject: 2003-08-14 Elena Zannoni X-Git-Tag: gdb_6_0-2003-10-04-release~110 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=640adc396ac421f9d8d3f99e3932570d1930da76;p=thirdparty%2Fbinutils-gdb.git 2003-08-14 Elena Zannoni * symfile.c (symbol_file_add_with_addrs_or_offsets): Make sure orig_addrs is set up properly. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index c8a58f5aa93..a520ffebfa9 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2003-08-14 Elena Zannoni + + * symfile.c (symbol_file_add_with_addrs_or_offsets): Make sure + orig_addrs is set up properly. + 2003-08-10 Mark Kettenis Based on a patch from Michael Elizabeth Chastain (mec@shout.net): diff --git a/gdb/symfile.c b/gdb/symfile.c index 839a7bc366e..2466649628c 100644 --- a/gdb/symfile.c +++ b/gdb/symfile.c @@ -854,7 +854,12 @@ symbol_file_add_with_addrs_or_offsets (char *name, int from_tty, orig_addrs = alloc_section_addr_info (bfd_count_sections (abfd)); my_cleanups = make_cleanup (xfree, orig_addrs); if (addrs) - *orig_addrs = *addrs; + { + int i; + orig_addrs->num_sections = addrs->num_sections; + for (i = 0; i < addrs->num_sections; i++) + orig_addrs->other[i] = addrs->other[i]; + } /* If the objfile uses a mapped symbol file, and we have a psymtab for it, then skip reading any symbols at this time. */