2009-04-22 Roland McGrath <roland@redhat.com>
+ * relocate.c (resolve_symbol): Apply correct bias to st_value found in
+ a non-ET_REL module.
+
* dwfl_module_build_id.c (__libdwfl_find_build_id): Fix last change to
adjust properly for non-ET_REL.
continue;
/* We found it! */
- if (shndx == SHN_ABS)
+ if (shndx == SHN_ABS) /* XXX maybe should apply bias? */
return DWFL_E_NOERROR;
+ if (m->e_type != ET_REL)
+ {
+ sym->st_value += m->symfile->bias;
+ return DWFL_E_NOERROR;
+ }
+
/* In an ET_REL file, the symbol table values are relative
to the section, not to the module's load base. */
size_t symshstrndx = SHN_UNDEF;