]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
* cris-dis.c (format_hex): Remove ineffective warning fix.
authorAlan Modra <amodra@gmail.com>
Thu, 24 Feb 2005 13:38:01 +0000 (13:38 +0000)
committerAlan Modra <amodra@gmail.com>
Thu, 24 Feb 2005 13:38:01 +0000 (13:38 +0000)
* crx-dis.c (make_instruction): Warning fix.
* frv-asm.c: Regenerate.

opcodes/ChangeLog
opcodes/cris-dis.c
opcodes/crx-dis.c
opcodes/frv-asm.c

index e01507f95aac6b59818d2beae64dba29ca21a383..e8c62ade31a31d801c12851d3be3fa669246d65d 100644 (file)
@@ -1,3 +1,9 @@
+2005-02-24  Alan Modra  <amodra@bigpond.net.au>
+
+       * cris-dis.c (format_hex): Remove ineffective warning fix.
+       * crx-dis.c (make_instruction): Warning fix.
+       * frv-asm.c: Regenerate.
+
 2005-02-23  Nick Clifton  <nickc@redhat.com>
 
        * cgen-dis.in: Use bfd_byte for buffers that are passed to
index 372f08512bcc9343572919d6f69298e0be123a80..b6b7559ed6e1261e9e6a8c227a1e35eb82ca1fd6 100644 (file)
@@ -448,10 +448,8 @@ format_hex (number, outbuffer, disdata)
      char *outbuffer;
      struct cris_disasm_data *disdata;
 {
-  /* Obfuscate to avoid warning on 32-bit host, but properly truncate
-     negative numbers on >32-bit hosts.  */
-  if (sizeof (number) > 4)
-    number &= (1 << (sizeof (number) > 4 ? 32 : 1)) - 1;
+  /* Truncate negative numbers on >32-bit hosts.  */
+  number &= 0xffffffff;
 
   sprintf (outbuffer, "0x%lx", number);
 
index 928b0117c4e0f3ea3e5e8732f655cee8b141ecd3..640a90a5e5c64c5c4ccb87b94408eddf61c04295 100644 (file)
@@ -658,8 +658,9 @@ make_instruction (void)
 
   for (i = 0; i < currInsn.nargs; i++)
     {
-      argument a = { 0 };
+      argument a;
 
+      memset (&a, 0, sizeof (a));
       a.type = getargtype (instruction->operands[i].op_type);
       if (instruction->operands[i].op_type == cst4
          || instruction->operands[i].op_type == rbase_dispu4)
index 635f9c742c650553cd7de9219679a2c7988bd979..2632e8777788d632a1a61e92de0dfae4aa58d7ea 100644 (file)
@@ -71,7 +71,7 @@ static const char * parse_A0
 static const char * parse_A1
   PARAMS ((CGEN_CPU_DESC, const char **, int, unsigned long *));
 static const char * parse_A
-  PARAMS ((CGEN_CPU_DESC, const char **, int, unsigned long *, long));
+  PARAMS ((CGEN_CPU_DESC, const char **, int, unsigned long *, unsigned long));
 
 inline static const char *
 parse_symbolic_address (CGEN_CPU_DESC cd,
@@ -924,7 +924,7 @@ parse_A (cd, strp, opindex, valuep, A)
      const char **strp;
      int opindex;
      unsigned long *valuep;
-     long A;
+     unsigned long A;
 {
   const char *errmsg;