2009-03-09 Roland McGrath <roland@redhat.com>
+ * dwfl_module_build_id.c (__libdwfl_find_build_id): Move SHSTRNDX
+ variable to outer scope, so we cache it for the loop.
+
* relocate.c (__libdwfl_relocate_value): Add MOD->main.bias to sh_addr.
2009-02-12 Roland McGrath <roland@redhat.com>
internal_function
__libdwfl_find_build_id (Dwfl_Module *mod, bool set, Elf *elf)
{
+ size_t shstrndx = SHN_UNDEF;
int result = 0;
Elf_Scn *scn = elf_nextscn (elf, NULL);
if (likely (shdr != NULL) && shdr->sh_type == SHT_NOTE)
{
/* Determine the right sh_addr in this module. */
- size_t shstrndx = SHN_UNDEF;
GElf_Addr vaddr = 0;
if (!(shdr->sh_flags & SHF_ALLOC)
|| __libdwfl_relocate_value (mod, elf, &shstrndx,