]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
Merge branch 'dwarf' into pmachata/dwarflint
authorPetr Machata <pmachata@redhat.com>
Thu, 14 Apr 2011 16:33:24 +0000 (18:33 +0200)
committerPetr Machata <pmachata@redhat.com>
Thu, 14 Apr 2011 16:33:24 +0000 (18:33 +0200)
Conflicts:
dwarflint/messages.cc

1  2 
dwarflint/Makefile.am
dwarflint/check_debug_info.cc
dwarflint/messages.cc
dwarflint/tests/run-DW_AT-later-version.sh

Simple merge
Simple merge
index e7ea4a495e66fa930a4366db6dda6cc5689fc3ce,995220c3ff8c08bbe085df1db63dd45af7f8d64f..7b6bb0839b354978a47a4564dbbaeed87be40c2a
@@@ -263,11 -256,11 +263,11 @@@ wr_verror (locus const &loc, const cha
  }
  
  static void
 -wr_vwarning (const struct where *wh, const char *format, va_list ap)
 +wr_vwarning (locus const &loc, const char *format, va_list ap)
  {
-   printf ("warning: %s", loc.format ().c_str ());
 -  printf ("%s", where_fmt (wh, NULL));
++  printf ("%s", loc.format ().c_str ());
    vprintf (format, ap);
 -  where_fmt_chain (wh, "warning");
 +  format_chain (loc, "warning");
    ++error_count;
  }
  
@@@ -286,12 -279,16 +286,16 @@@ wr_message (unsigned long category, loc
  {
    va_list ap;
    va_start (ap, format);
-   if (message_accept (&warning_criteria, category))
+   // Clumsy duplicate filtering. Use format as key.
+   bool whether = false;
+   message_category cat = (message_category) category;
+   wr_message (cat).id (format, whether);
+   if (whether && message_accept (&warning_criteria, category))
      {
        if (message_accept (&error_criteria, category))
 -      wr_verror (wh, format, ap);
 +      wr_verror (*loc, format, ap);
        else
 -      wr_vwarning (wh, format, ap);
 +      wr_vwarning (*loc, format, ap);
      }
    va_end (ap);
  }
index 92dc17a341c92357f1446e80037be8344af8ae21,3565dc88c03e126024d4df8921c6ae60498bc941..00b9a35339567273e295a39f7528ed97a3ccd2be
@@@ -30,6 -30,7 +30,7 @@@ srcdir=$srcdir/test
  testfiles DW_AT-later-version
  
  testrun_compare ./dwarflint --nognu DW_AT-later-version <<EOF
 -warning: .debug_abbrev: abbr. attribute 0x15: attribute DW_AT_endianity from later DWARF version.
 +warning: .debug_abbrev: abbr. 0x11, attr. endianity: attribute from later DWARF version.
  warning: .debug_info: DIE 0xb: DW_AT_low_pc value not below DW_AT_high_pc.
+ warning: .debug_info: DIE 0x29: variable has decl_file, but NOT decl_line
  EOF