From ae4d0c03d93ab5c671f7cb68c736ae2f28f3ec0b Mon Sep 17 00:00:00 2001 From: Pierre Muller Date: Tue, 1 Jun 2010 21:34:15 +0000 Subject: [PATCH] * dwarf2read.c (read_func_scope): Do not complain for external function if bounds are not found. --- gdb/ChangeLog | 5 +++++ gdb/dwarf2read.c | 8 +++++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 87facb9..176a6ec 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2010-06-01 Pierre Muller + + * dwarf2read.c (read_func_scope): Do not complain for + external function if bounds are not found. + 2010-06-01 Pedro Alves * NEWS: Mention gdbserver fast tracepoints support. diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c index 129d6c1..254d899 100644 --- a/gdb/dwarf2read.c +++ b/gdb/dwarf2read.c @@ -3904,9 +3904,11 @@ read_func_scope (struct die_info *die, struct dwarf2_cu *cu) /* Ignore functions with missing or invalid low and high pc attributes. */ if (!dwarf2_get_pc_bounds (die, &lowpc, &highpc, cu, NULL)) { - complaint (&symfile_complaints, - _("cannot get low and high bounds for subprogram DIE at %d"), - die->offset); + attr = dwarf2_attr (die, DW_AT_external, cu); + if (!attr || !DW_UNSND (attr)) + complaint (&symfile_complaints, + _("cannot get low and high bounds for subprogram DIE at %d"), + die->offset); return; } -- 2.7.4