ARC: Use of uninitialised value
authorAlan Modra <amodra@gmail.com>
Sun, 22 Mar 2020 09:32:55 +0000 (20:02 +1030)
committerAlan Modra <amodra@gmail.com>
Sun, 22 Mar 2020 12:52:13 +0000 (23:22 +1030)
* arc-dis.c (find_format): Use ISO C string concatenation rather
than line continuation within a string.  Don't access needs_limm
before testing opcode != NULL.

opcodes/ChangeLog
opcodes/arc-dis.c

index 06b81d7b54795edc579b561d779be808322092bc..eb3e4c32f2902c4196332f6c12f08349a11ed3e0 100644 (file)
@@ -1,3 +1,9 @@
+2020-03-22  Alan Modra  <amodra@gmail.com>
+
+       * arc-dis.c (find_format): Use ISO C string concatenation rather
+       than line continuation within a string.  Don't access needs_limm
+       before testing opcode != NULL.
+
 2020-03-22  Alan Modra  <amodra@gmail.com>
 
        * ns32k-dis.c (print_insn_arg): Update comment.
index 9662c2fc53bf3b406068ad4bce3d1f12ee4fa6a0..131aee6b34e546f69fe8b93f4d96d0884c7db21b 100644 (file)
@@ -436,8 +436,9 @@ find_format (bfd_vma                       memaddr,
          opcode = arcExtMap_genOpcode (i, isa_mask, &errmsg);
          if (opcode == NULL)
            {
-             (*info->fprintf_func) (info->stream, "\
-An error occured while generating the extension instruction operations");
+             (*info->fprintf_func) (info->stream,
+                                    _("An error occured while generating the "
+                                      "extension instruction operations"));
              *opcode_result = NULL;
              return FALSE;
            }
@@ -452,7 +453,7 @@ An error occured while generating the extension instruction operations");
     opcode = find_format_from_table (info, arc_opcodes, insn, *insn_len,
                                     isa_mask, &needs_limm, TRUE);
 
-  if (needs_limm && opcode != NULL)
+  if (opcode != NULL && needs_limm)
     {
       bfd_byte buffer[4];
       int status;
This page took 0.025066 seconds and 4 git commands to generate.