From: Roland McGrath Date: Thu, 6 May 2010 08:12:15 +0000 (-0700) Subject: libdwfl: Another segment lookup table nit. X-Git-Tag: elfutils-0.148~55 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=aba26e0f182acb8a40854f4d92a5a7897984d7f1;p=platform%2Fupstream%2Felfutils.git libdwfl: Another segment lookup table nit. --- diff --git a/libdwfl/ChangeLog b/libdwfl/ChangeLog index b1ba7a5..8d87d19 100644 --- a/libdwfl/ChangeLog +++ b/libdwfl/ChangeLog @@ -1,5 +1,7 @@ 2010-05-06 Roland McGrath + * segment.c (insert): Clear inserted elements of DWFL->lookup_module. + * libdwflP.h (DWFL_ERRORS): Add WRONG_ID_ELF. * dwfl_build_id_find_elf.c: Set MOD->main.valid when there is a build ID but we didn't find a file. diff --git a/libdwfl/segment.c b/libdwfl/segment.c index d39fdab..9d78c87 100644 --- a/libdwfl/segment.c +++ b/libdwfl/segment.c @@ -121,6 +121,8 @@ insert (Dwfl *dwfl, size_t i, GElf_Addr start, GElf_Addr end, int segndx) { dwfl->lookup_addr[i] = start; dwfl->lookup_segndx[i] = segndx; + if (dwfl->lookup_module != NULL) + dwfl->lookup_module[i] = NULL; ++i; } else @@ -130,6 +132,8 @@ insert (Dwfl *dwfl, size_t i, GElf_Addr start, GElf_Addr end, int segndx) { dwfl->lookup_addr[i] = end; dwfl->lookup_segndx[i] = -1; + if (dwfl->lookup_module != NULL) + dwfl->lookup_module[i] = NULL; } dwfl->lookup_elts += need;