Skip to contentSkip to conversation

target-ppc: Fix Temporary Variable Leak in bctar

PATCH Applied Tom Musta 2 participants 2 messages Jun 4, 2014

lore
Share & tools
lore

Tom Musta

author
#0 lore raw

PATCH 1/1 target-ppc: Fix Temporary Variable Leak in bctar

Fix a temporary variable leak detected in the bctar instruction:

Opcode 13 10 11 (4d910460) leaked temporaries

---
 target-ppc/translate.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
target-ppc/translate.c +1 -1
index 2de362c..3a8d702 100644
@@ -3891,7 +3891,7 @@ static inline void gen_bcond(DisasContext *ctx, int type)
         gen_update_nip(ctx, ctx->nip);
         tcg_gen_exit_tb(0);
     }
-    if (type == BCOND_LR || type == BCOND_CTR) {
+    if (type == BCOND_LR || type == BCOND_CTR || type == BCOND_TAR) {
         tcg_temp_free(target);
     }
 }
Signature · 1 line
1.7.1
#1 lore raw
Quoted 5 lines · Tom Musta

Fix a temporary variable leak detected in the bctar instruction:

    Opcode 13 10 11 (4d910460) leaked temporaries

Thanks, applied to ppc-next.

Alex