]> www.infradead.org Git - users/dwmw2/qemu.git/commitdiff
target/m68k: Fix a tcg_temp leak
authorPhilippe Mathieu-Daudé <f4bug@amsat.org>
Sun, 10 Mar 2019 00:34:25 +0000 (01:34 +0100)
committerMichael Roth <mdroth@linux.vnet.ibm.com>
Tue, 30 Jul 2019 19:33:20 +0000 (14:33 -0500)
The function gen_get_ccr() returns a tcg_temp created with
tcg_temp_new(). Free it with tcg_temp_free().

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20190310003428.11723-4-f4bug@amsat.org>
Signed-off-by: Laurent Vivier <laurent@vivier.eu>
(cherry picked from commit 44c64e90950adf9efe7f4235a32eb868d1290ebb)
Signed-off-by: Michael Roth <mdroth@linux.vnet.ibm.com>
target/m68k/translate.c

index 752e46ef63f85e1881db4799aa848285a56ea1fd..08e259d6eae1ad043a57a359ca25627af75284b5 100644 (file)
@@ -2226,6 +2226,7 @@ static TCGv gen_get_sr(DisasContext *s)
     sr = tcg_temp_new();
     tcg_gen_andi_i32(sr, QREG_SR, 0xffe0);
     tcg_gen_or_i32(sr, sr, ccr);
+    tcg_temp_free(ccr);
     return sr;
 }