|
|
@ -693,10 +693,15 @@ void bfdFillAdditionalFunctionsInfo(BacktraceFunctionInfo &func) {
|
|
|
|
|
|
|
|
|
|
|
|
// found source file and line for given address
|
|
|
|
// found source file and line for given address
|
|
|
|
for (asection *sect = abfd->sections; sect != NULL; sect = sect->next) {
|
|
|
|
for (asection *sect = abfd->sections; sect != NULL; sect = sect->next) {
|
|
|
|
|
|
|
|
#ifdef HAVE_LIBBFD_2_34_API
|
|
|
|
|
|
|
|
if (bfd_section_flags(sect) & SEC_ALLOC) {
|
|
|
|
|
|
|
|
bfd_vma sectStart = bfd_section_vma(sect);
|
|
|
|
|
|
|
|
bfd_vma sectEnd = sectStart + bfd_section_size(sect);
|
|
|
|
|
|
|
|
#else // HAVE_LIBBFD_2_34_API
|
|
|
|
if (bfd_get_section_flags(abfd, sect) & SEC_ALLOC) {
|
|
|
|
if (bfd_get_section_flags(abfd, sect) & SEC_ALLOC) {
|
|
|
|
bfd_vma sectStart = bfd_get_section_vma(abfd, sect);
|
|
|
|
bfd_vma sectStart = bfd_get_section_vma(abfd, sect);
|
|
|
|
bfd_vma sectEnd = sectStart + bfd_section_size(abfd, sect);
|
|
|
|
bfd_vma sectEnd = sectStart + bfd_section_size(abfd, sect);
|
|
|
|
|
|
|
|
#endif // HAVE_LIBBFD_2_34_API
|
|
|
|
if (sectStart <= func.offset && func.offset < sectEnd) {
|
|
|
|
if (sectStart <= func.offset && func.offset < sectEnd) {
|
|
|
|
bfd_vma sectOffset = func.offset - sectStart;
|
|
|
|
bfd_vma sectOffset = func.offset - sectStart;
|
|
|
|
const char* functionName;
|
|
|
|
const char* functionName;
|
|
|
|