This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PR15206 patch broke build


binutils/dwarf.c: In function âread_and_display_attr_valueâ:
binutils/dwarf.c:1588:2: error: field precision specifier â.*â expects argument of type âintâ, but argument 2 has type âlong intâ [-Werror=format]

	* dwarf.c (read_and_display_attr_value): Cast format '*' arg to int.

Index: binutils/dwarf.c
===================================================================
RCS file: /cvs/src/src/binutils/dwarf.c,v
retrieving revision 1.127
diff -u -p -r1.127 dwarf.c
--- binutils/dwarf.c	26 Mar 2013 22:51:12 -0000	1.127
+++ binutils/dwarf.c	26 Mar 2013 23:53:49 -0000
@@ -1585,7 +1585,7 @@ read_and_display_attr_value (unsigned lo
 
     case DW_FORM_string:
       if (!do_loc)
-	printf (" %.*s", end - data, data);
+	printf (" %.*s", (int) (end - data), data);
       data += strnlen ((char *) data, end - data) + 1;
       break;
 
-- 
Alan Modra
Australia Development Lab, IBM


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]