libdw: Handle all address FORMs for dwarf_highpc, handle errors better.
authorMark Wielaard <mark@klomp.org>
Tue, 22 May 2018 12:34:06 +0000 (14:34 +0200)
committerMark Wielaard <mark@klomp.org>
Fri, 25 May 2018 13:10:40 +0000 (15:10 +0200)
commite7765da2aebf919bf3ab8480ac07ccdee42aaf8d
treebe455dd507a73736b72a5b86d223a603f23d0fde
parent6e3d2521a2b5a3b436901f52cfb9785887a7c961
libdw: Handle all address FORMs for dwarf_highpc, handle errors better.

dwarf_highpc can use any address FORM, not just DW_FORM_addr. Just try
whether the address can be resolved as address. Always set error when
attribute couldn't be found or resolved. When calculating the base
address for a CU don't try to second guess the error code, just treat
an error the same as the attribute not being there.

Signed-off-by: Mark Wielaard <mark@klomp.org>
libdw/ChangeLog
libdw/dwarf_getlocation.c
libdw/dwarf_highpc.c