]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
readelf.c: Cast printf PRIu/x64 arguments to uint64_t for gcc 4.7 -Wformat.
authorMark Wielaard <mjw@redhat.com>
Fri, 22 Jun 2012 14:44:54 +0000 (16:44 +0200)
committerMark Wielaard <mjw@redhat.com>
Fri, 22 Jun 2012 16:15:30 +0000 (18:15 +0200)
Signed-off-by: Mark Wielaard <mjw@redhat.com>
src/ChangeLog
src/readelf.c

index af1d92bd767cb404d09724e8ab830a456d58c3af..40905b8a3f0c436b9bb8c6eedccac2ab328e4343 100644 (file)
@@ -1,3 +1,8 @@
+2012-06-22  Mark Wielaard  <mjw@redhat.com>
+
+       * readelf.c (print_ops): Cast printf PRIu/x64 arguments to uint64_t
+       for gcc 4.7 -Wformat.
+
 2012-05-09  Roland McGrath  <roland@hack.frob.com>
 
        * elflint (check_sections): Allow zero sized sections at (filesz) end
index 5dc9b6fe650bc9f3eb16982e668ab2fe7193c0c6..d182ab50bdb318468a361e94c647c1af13d617ef 100644 (file)
@@ -4167,7 +4167,7 @@ print_ops (Dwfl_Module *dwflmod, Dwarf *dbg, int indent, int indentrest,
          // XXX value might be modified by relocation
          printf ("%*s[%4" PRIuMAX "] %s %" PRIu64 "\n",
                  indent, "", (uintmax_t) offset,
-                 known[op], read_8ubyte_unaligned (dbg, data));
+                 known[op], (uint64_t) read_8ubyte_unaligned (dbg, data));
          CONSUME (8);
          data += 8;
          offset += 9;
@@ -5606,7 +5606,7 @@ attr_callback (Dwarf_Attribute *attrp, void *arg)
       printf ("           %*s%-20s (%s) {%6" PRIx64 "}\n",
              (int) (level * 2), "", dwarf_attr_string (attr),
              dwarf_form_string (form),
-             read_8ubyte_unaligned (attrp->cu->dbg, attrp->valp));
+             (uint64_t) read_8ubyte_unaligned (attrp->cu->dbg, attrp->valp));
       break;
 
     case DW_FORM_sec_offset: