change in getting section size for SUN Solaris (old bfd.h)

master
Marc Wäckerlin 20 years ago
parent 6178545a15
commit 778065506f
  1. 9
      mrw/stacktrace.cpp

@ -9,6 +9,9 @@
@license LGPL, see file <a href="license.html">COPYING</a>
$Log$
Revision 1.12 2005/02/28 07:14:03 marc
change in getting section size for SUN Solaris (old bfd.h)
Revision 1.11 2005/02/18 15:48:56 marc
Dynamic loading of libbfd, no more dependency on specific libbfd version!
@ -330,7 +333,13 @@ void mrw::StackTrace::buildSectionMap(bfd* abfd, asection* section,
*(std::pair<std::string, void*>*)fileoffs;
bfd_vma vma(bfd_get_section_vma(abfd, section)+
reinterpret_cast<bfd_vma>(fileoffset.second));
#ifdef bfd_get_section_size
bfd_size_type sz(bfd_get_section_size(section));
#elsifdef bfd_get_section_size_before_reloc
bfd_size_type sz(bfd_get_section_size_before_reloc(section));
#else
bfd_size_type sz(section->size);
#endif
_dic[fileoffset.first][vma] = Translator::mapped_type(vma+sz, section);
_addrs[vma] = fileoffset.first;
}

Loading…
Cancel
Save