aboutsummaryrefslogtreecommitdiff
path: root/opcodes/cgen-opc.c
diff options
context:
space:
mode:
Diffstat (limited to 'opcodes/cgen-opc.c')
-rw-r--r--opcodes/cgen-opc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/opcodes/cgen-opc.c b/opcodes/cgen-opc.c
index d637c7c..543ce32 100644
--- a/opcodes/cgen-opc.c
+++ b/opcodes/cgen-opc.c
@@ -460,9 +460,10 @@ cgen_lookup_insn (CGEN_CPU_DESC cd,
if (cd->int_insn_p)
{
info = NULL;
- buf = (unsigned char *) alloca (cd->max_insn_bitsize / 8);
+ buf = (unsigned char *) xmalloc (cd->max_insn_bitsize / 8);
cgen_put_insn_value (cd, buf, length, insn_int_value);
base_insn = insn_int_value;
+ free (buf);
}
else
{