diff options
| author | Ed Maste <emaste@FreeBSD.org> | 2014-12-30 01:27:18 +0000 |
|---|---|---|
| committer | Ed Maste <emaste@FreeBSD.org> | 2014-12-30 01:27:18 +0000 |
| commit | 42bfa111d731278ff40f9ce45298e65a373c2064 (patch) | |
| tree | 93decb044b3639075e37c0f46bef0c1b6a0529f8 /libdwarf/libdwarf_abbrev.c | |
| parent | 5eccfb5cf5403e9e564066e0a75d80534b49e91d (diff) | |
Diffstat (limited to 'libdwarf/libdwarf_abbrev.c')
| -rw-r--r-- | libdwarf/libdwarf_abbrev.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/libdwarf/libdwarf_abbrev.c b/libdwarf/libdwarf_abbrev.c index f4a395df03606..abcc2fda9580d 100644 --- a/libdwarf/libdwarf_abbrev.c +++ b/libdwarf/libdwarf_abbrev.c @@ -27,7 +27,7 @@ #include "_libdwarf.h" -ELFTC_VCSID("$Id: libdwarf_abbrev.c 2070 2011-10-27 03:05:32Z jkoshy $"); +ELFTC_VCSID("$Id: libdwarf_abbrev.c 3136 2014-12-24 16:04:38Z kaiwang27 $"); int _dwarf_abbrev_add(Dwarf_CU cu, uint64_t entry, uint64_t tag, uint8_t children, @@ -180,7 +180,9 @@ _dwarf_abbrev_find(Dwarf_CU cu, uint64_t entry, Dwarf_Abbrev *abp, /* Load and search the abbrev table. */ ds = _dwarf_find_section(cu->cu_dbg, ".debug_abbrev"); - assert(ds != NULL); + if (ds == NULL) + return (DW_DLE_NO_ENTRY); + offset = cu->cu_abbrev_offset_cur; while (offset < ds->ds_size) { ret = _dwarf_abbrev_parse(cu->cu_dbg, cu, &offset, &ab, error); |
