* dwarf2read.c (new_symbol): Handle DW_AT_decl_file being zero.
authorMark Kettenis <kettenis@gnu.org>
Sun, 28 Jan 2007 14:42:12 +0000 (14:42 +0000)
committerMark Kettenis <kettenis@gnu.org>
Sun, 28 Jan 2007 14:42:12 +0000 (14:42 +0000)
gdb/ChangeLog
gdb/dwarf2read.c

index ccf63eeb7bf500f5af6c7587c81a4343894023fd..1fa6676aca58122d29649ae814fa8ed3c3a0621f 100644 (file)
@@ -1,3 +1,7 @@
+2007-01-28  Mark Kettenis  <kettenis@gnu.org>
+
+       * dwarf2read.c (new_symbol): Handle DW_AT_decl_file being zero.
+
 2007-01-27  Daniel Jacobowitz  <dan@codesourcery.com>
 
        * dwarf2loc.h (struct dwarf2_locexpr_baton): Change size to a long.
index 9894bf0f1e3b075d5ab855a15ea2d6d0869f1ab9..3c61f9a0e84020660c5f1bf92ef9dd22a6180db3 100644 (file)
@@ -7079,7 +7079,7 @@ new_symbol (struct die_info *die, struct type *type, struct dwarf2_cu *cu)
              || file_index > cu->line_header->num_file_names)
            complaint (&symfile_complaints,
                       _("file index out of range"));
-         else
+         else if (file_index > 0)
            {
              struct file_entry *fe;
              fe = &cu->line_header->file_names[file_index - 1];