diff options
author | Josh Stone <jistone@redhat.com> | 2009-05-15 15:54:43 -0700 |
---|---|---|
committer | Josh Stone <jistone@redhat.com> | 2009-05-15 15:54:43 -0700 |
commit | 62f6ae64f9d1269e07d320e9a168ee737b2cf851 (patch) | |
tree | b474047606097a4053c01ce79333ca450bd69f64 /dwarf_wrappers.cxx | |
parent | 3863e7999255deeaa7f8f4bba7df893773812537 (diff) | |
parent | d0b4a5ffde2a86bc672097a4d5462b204364e59f (diff) | |
download | systemtap-steved-62f6ae64f9d1269e07d320e9a168ee737b2cf851.tar.gz systemtap-steved-62f6ae64f9d1269e07d320e9a168ee737b2cf851.tar.xz systemtap-steved-62f6ae64f9d1269e07d320e9a168ee737b2cf851.zip |
Merge branch 'tapsets-cleanup'
Diffstat (limited to 'dwarf_wrappers.cxx')
-rw-r--r-- | dwarf_wrappers.cxx | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/dwarf_wrappers.cxx b/dwarf_wrappers.cxx index 3627b989..d7183dc3 100644 --- a/dwarf_wrappers.cxx +++ b/dwarf_wrappers.cxx @@ -12,6 +12,7 @@ #include <cstring> #include <string> #include <elfutils/libdwfl.h> +#include <dwarf.h> using std::string; @@ -45,4 +46,16 @@ void dwfl_assert(const std::string& desc, bool condition) dwfl_assert(desc, -1); } + +// Helper for dealing with selected portions of libdwfl in a more readable +// fashion, and with specific cleanup / checking / logging options. + +const char * +dwarf_diename_integrate (Dwarf_Die *die) +{ + Dwarf_Attribute attr_mem; + return dwarf_formstring (dwarf_attr_integrate (die, DW_AT_name, &attr_mem)); +} + + /* vim: set sw=2 ts=8 cino=>4,n-2,{2,^-2,t0,(0,u0,w1,M1 : */ |