This is the mail archive of the binutils@sources.redhat.com 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]

fix a gas error message


Seen on powerpc-linux gas compiled with a 64-bit bfd.  Passing a 64-bit
offsetT to printf and expecting %d to print something sensible doesn't
work..

gas/ChangeLog
	* messages.c (as_internal_value_out_of_range): Cast values passed
	to as_bad_where or as_warn_where to proper type.

Index: gas/messages.c
===================================================================
RCS file: /cvs/src/src/gas/messages.c,v
retrieving revision 1.9
diff -u -p -r1.9 messages.c
--- gas/messages.c	6 May 2004 11:01:48 -0000	1.9
+++ gas/messages.c	13 Sep 2004 00:44:56 -0000
@@ -534,9 +534,11 @@ as_internal_value_out_of_range (char *  
       err = _("%s out of range (%d is not between %d and %d)");
 
       if (bad)
-	as_bad_where (file, line, err, prefix, val, min, max);
+	as_bad_where (file, line, err,
+		      prefix, (int) val, (int) min, (int) max);
       else
-	as_warn_where (file, line, err, prefix, val, min, max);
+	as_warn_where (file, line, err,
+		       prefix, (int) val, (int) min, (int) max);
     }
 #ifdef BFD_ASSEMBLER
   else

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre


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