diff options
Diffstat (limited to 'libdw/dwarf_formflag.c')
-rw-r--r-- | libdw/dwarf_formflag.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/libdw/dwarf_formflag.c b/libdw/dwarf_formflag.c index 4e57c3af..fb60c8e6 100644 --- a/libdw/dwarf_formflag.c +++ b/libdw/dwarf_formflag.c @@ -1,5 +1,5 @@ /* Return flag represented by attribute. - Copyright (C) 2004 Red Hat, Inc. + Copyright (C) 2004-2009 Red Hat, Inc. This file is part of Red Hat elfutils. Written by Ulrich Drepper <drepper@redhat.com>, 2004. @@ -64,6 +64,12 @@ dwarf_formflag (attr, return_bool) if (attr == NULL) return -1; + if (attr->form == DW_FORM_flag_present) + { + *return_bool = true; + return 0; + } + if (unlikely (attr->form != DW_FORM_flag)) { __libdw_seterrno (DWARF_E_NO_FLAG); |