[PATCH] readelf: Report error when decl_file or call_file attribute is invalid.

Mark Wielaard mark@klomp.org
Tue Mar 27 14:26:00 GMT 2018


On Tue, 2018-03-27 at 15:42 +0200, Mark Wielaard wrote:
> On Tue, 2018-03-20 at 13:33 +0100, Mark Wielaard wrote:
> > Report an error for why the DW_AT_decl_file or DW_AT_call_file
> > cannot
> > be resolved to a file name. This is likely invalid DWARF, a missing
> > DW_AT_stmt_list attribute on the CU or a missing .debug_line
> > section.
> 
> I pushed this to master

And the buildbot flagged an issue on debian-i686:
https://builder.wildebeest.org/buildbot/#/builders/4/builds/110

readelf.c: In function ‘attr_callback’:
readelf.c:6261:27: error: format ‘%zx’ expects argument of type ‘size_t’, but argument 4 has type ‘Dwarf_Off {aka long long unsigned int}’ [-Werror=format=]
     error (0, 0, gettext ("no srcfiles for CU [%zx]"),
                           ^

Oops. Sorry about that. Fixed as attached.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-readelf-Print-dwarf_dieoffset-as-PRIx64-not-zx.patch
Type: text/x-patch
Size: 1199 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/elfutils-devel/attachments/20180327/c0188036/attachment.bin>


More information about the Elfutils-devel mailing list