diff options
| author | Mark Wielaard <[email protected]> | 2013-02-15 22:45:22 +0100 |
|---|---|---|
| committer | Mark Wielaard <[email protected]> | 2013-02-15 22:45:22 +0100 |
| commit | 443304efce95d66ac089d95807a0002cf8558d13 (patch) | |
| tree | 875184126e0c46a80524e88396222ba9f0c4fe3f /libdw | |
| parent | 40025813dc9e5f2524c3c1851a99efd43cb59894 (diff) | |
libdw: Handle FORM_GNU_strp_alt for files with string data only in dwz file.
dwarf_formstring should check that the dbg file from which we want the
strp data actually has a IDX_debug_str section.
Reported-By: Tom Tromey <[email protected]>
Signed-off-by: Mark Wielaard <[email protected]>
Diffstat (limited to 'libdw')
| -rw-r--r-- | libdw/ChangeLog | 5 | ||||
| -rw-r--r-- | libdw/dwarf_formstring.c | 4 |
2 files changed, 7 insertions, 2 deletions
diff --git a/libdw/ChangeLog b/libdw/ChangeLog index 3cf30324..2900ef6c 100644 --- a/libdw/ChangeLog +++ b/libdw/ChangeLog @@ -1,3 +1,8 @@ +2013-02-15 Mark Wielaard <[email protected]> + + * dwarf_formstring.c (dwarf_formstring): Check dbg_ret->sectiondata, + not dbg->sectiondata. + 2013-01-07 Roland McGrath <[email protected]> * memory-access.h diff --git a/libdw/dwarf_formstring.c b/libdw/dwarf_formstring.c index c66454e1..02b56d4a 100644 --- a/libdw/dwarf_formstring.c +++ b/libdw/dwarf_formstring.c @@ -1,5 +1,5 @@ /* Return string associated with given attribute. - Copyright (C) 2003-2010 Red Hat, Inc. + Copyright (C) 2003-2010, 2013 Red Hat, Inc. This file is part of elfutils. Written by Ulrich Drepper <[email protected]>, 2003. @@ -60,7 +60,7 @@ dwarf_formstring (attrp) if (unlikely (attrp->form != DW_FORM_strp && attrp->form != DW_FORM_GNU_strp_alt) - || dbg->sectiondata[IDX_debug_str] == NULL) + || dbg_ret->sectiondata[IDX_debug_str] == NULL) { __libdw_seterrno (DWARF_E_NO_STRING); return NULL; |
