libdw: Handle empty location expression for (indirect) DIE locations.
authorMark Wielaard <mjw@redhat.com>
Mon, 9 Dec 2013 15:33:26 +0000 (16:33 +0100)
committerMark Wielaard <mjw@redhat.com>
Fri, 13 Dec 2013 13:23:02 +0000 (14:23 +0100)
commit3951f2ec0aaca021c77a2c7a464dcf43433261c3
treeae53cf11004fbb40596d7ccde179100b52f3fa20
parent8b10aaa3dd3db1981aee29cf8f88411707172295
libdw: Handle empty location expression for (indirect) DIE locations.

When dwarf_getlocation_implicit_pointer and dwarf_getlocation_attr
refer to a DIE that doesn't contain a DW_AT_location then don't generate
an error, but return an empty location expression to signal the actual
value pointed to is not available. This isn't invalid DWARF. Also make
sure that __libdw_intern_expression handles empty location expressions.

Signed-off-by: Mark Wielaard <mjw@redhat.com>
libdw/ChangeLog
libdw/dwarf_getlocation.c
libdw/dwarf_getlocation_attr.c
libdw/dwarf_getlocation_implicit_pointer.c
libdw/libdwP.h
tests/ChangeLog
tests/varlocs.c