* opncls.c (_maybe_make_executable): New function. Gives execute
[deliverable/binutils-gdb.git] / opcodes / m32c-opc.c
index 9497896a874449aadd2d42f4ba2d68fd30beda59..ff2a72a7eeae8c1c9b123635e28530bbc569f566 100644 (file)
@@ -80213,7 +80213,10 @@ m32c_cgen_init_opcode_table (CGEN_CPU_DESC cd)
   const CGEN_OPCODE *oc = & m32c_cgen_macro_insn_opcode_table[0];
   CGEN_INSN *insns = xmalloc (num_macros * sizeof (CGEN_INSN));
 
-  memset (insns, 0, num_macros * sizeof (CGEN_INSN));
+  /* This test has been added to avoid a warning generated
+     if memset is called with a third argument of value zero.  */
+  if (num_macros >= 1)
+    memset (insns, 0, num_macros * sizeof (CGEN_INSN));
   for (i = 0; i < num_macros; ++i)
     {
       insns[i].base = &ib[i];
This page took 0.040106 seconds and 4 git commands to generate.