> 
> The fix is correct.  We just need the submission formatted properly, with 
> your 
> Signed-off-by tag.  When re-formatting, you can add my
> 
> Reviewed-by: Richard Henderson <richard.hender...@linaro.org>
> 

> r~

Hi guys,

Thank you for waiting for me.

Here is a new patch with Signed-off-by tags.

Best,
Wentao
From 15129e2cec483a8416738b266bc3b36d56959f69 Mon Sep 17 00:00:00 2001
From: Wentao_Liang <wentao_lian...@163.com>
Date: Fri, 25 Feb 2022 12:01:42 +0800
Subject: [PATCH] Fix a potential Use-after-free bug in
 handle_simd_shift_fpint_conv()

Signed-off-by: Wentao_Liang <wentao_lian...@163.com>
---
 target/arm/translate-a64.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/target/arm/translate-a64.c b/target/arm/translate-a64.c
index 5a1df25f91..d1a59fad9c 100644
--- a/target/arm/translate-a64.c
+++ b/target/arm/translate-a64.c
@@ -9045,9 +9045,9 @@ static void handle_simd_shift_fpint_conv(DisasContext *s, bool is_scalar,
         }
     }
 
-    tcg_temp_free_ptr(tcg_fpstatus);
     tcg_temp_free_i32(tcg_shift);
     gen_helper_set_rmode(tcg_rmode, tcg_rmode, tcg_fpstatus);
+    tcg_temp_free_ptr(tcg_fpstatus);
     tcg_temp_free_i32(tcg_rmode);
 }
 
-- 
2.25.1

Reply via email to