+2009-04-22 Roland McGrath <roland@redhat.com>
+
+ * dwfl_module_build_id.c (__libdwfl_find_build_id): Fix last change to
+ adjust properly for non-ET_REL.
+
2009-04-21 Roland McGrath <roland@redhat.com>
* dwfl_module_getsym.c: Apply non-ET_REL bias only if SHF_ALLOC.
{
/* Determine the right sh_addr in this module. */
GElf_Addr vaddr = 0;
- if (!(shdr->sh_flags & SHF_ALLOC)
- || (mod->e_type == ET_REL
- && __libdwfl_relocate_value (mod, elf, &shstrndx,
- elf_ndxscn (scn), &vaddr)))
+ if (!(shdr->sh_flags & SHF_ALLOC))
+ vaddr = NO_VADDR;
+ else if (mod->e_type != ET_REL)
+ vaddr = shdr->sh_addr + mod->main.bias;
+ else if (__libdwfl_relocate_value (mod, elf, &shstrndx,
+ elf_ndxscn (scn), &vaddr))
vaddr = NO_VADDR;
result = check_notes (mod, set, elf_getdata (scn, NULL), vaddr);
}