Merge branch 'master' into merge-job
[deliverable/binutils-gdb.git] / opcodes / h8300-dis.c
index 17a3cbdd34de292b50fa5f59108ba617d1619806..83a82c09bda74d30d75de50a5a5a82c29987372d 100644 (file)
@@ -1,5 +1,5 @@
 /* Disassemble h8300 instructions.
-   Copyright (C) 1993-2015 Free Software Foundation, Inc.
+   Copyright (C) 1993-2020 Free Software Foundation, Inc.
 
    This file is part of the GNU opcodes library.
 
@@ -23,7 +23,7 @@
 #include "sysdep.h"
 #define h8_opcodes h8ops
 #include "opcode/h8300.h"
-#include "dis-asm.h"
+#include "disassemble.h"
 #include "opintl.h"
 #include "libiberty.h"
 
@@ -59,7 +59,8 @@ bfd_h8_disassemble_init (void)
 
       if (i & 1)
        {
-         fprintf (stderr, "Internal error, h8_disassemble_init.\n");
+         /* xgettext:c-format */
+         opcodes_error_handler (_("internal error, h8_disassemble_init"));
          abort ();
        }
 
@@ -139,7 +140,8 @@ extract_immediate (FILE *stream,
       break;
     case L_32:
       *len = 32;
-      *cst = (data[0] << 24) + (data[1] << 16) + (data[2] << 8) + data[3];
+      *cst = (((unsigned) data[0] << 24) + (data[1] << 16)
+             + (data[2] << 8) + data[3]);
       break;
     default:
       *len = 0;
@@ -529,7 +531,7 @@ bfd_h8_disassemble (bfd_vma addr, disassemble_info *info, int mach)
                {
                  int i = len / 2;
 
-                 cst[opnr] = ((data[i] << 24)
+                 cst[opnr] = (((unsigned) data[i] << 24)
                               | (data[i + 1] << 16)
                               | (data[i + 2] << 8)
                               | (data[i + 3]));
This page took 0.023462 seconds and 4 git commands to generate.