From: Mark Wielaard Date: Fri, 17 Apr 2015 20:24:41 +0000 (+0200) Subject: readelf: Always try to print some debug section information. X-Git-Tag: elfutils-0.162~86 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=9b5f79511717cc26233dd06dd8dab148498db307;p=thirdparty%2Felfutils.git readelf: Always try to print some debug section information. Even if we cannot create a proper Dwarf dbg we can still print the information of various debug sections. All all debug print section functions already check first they can access the appropriate data. Signed-off-by: Mark Wielaard --- diff --git a/src/ChangeLog b/src/ChangeLog index 6985b5867..e92f11588 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2015-03-17 Mark Wielaard + + * readelf.c (print_debug): Don't return, but always use dummy_dbg. + 2015-03-17 Mark Wielaard * readelf.c (print_gdb_index_section): Add overflow checking for diff --git a/src/readelf.c b/src/readelf.c index b717757a1..7f84edafc 100644 --- a/src/readelf.c +++ b/src/readelf.c @@ -8188,8 +8188,6 @@ print_debug (Dwfl_Module *dwflmod, Ebl *ebl, GElf_Ehdr *ehdr) if ((print_debug_sections & ~section_exception) != 0) error (0, 0, gettext ("cannot get debug context descriptor: %s"), dwfl_errmsg (-1)); - if ((print_debug_sections & section_exception) == 0) - return; dbg = &dummy_dbg; }