From 640b104ac01aecd52323c52303c64dbdd2b5606a Mon Sep 17 00:00:00 2001 From: Lioncash Date: Mon, 5 Mar 2018 15:40:47 -0500 Subject: [PATCH] translate-all: Zero out the TCGContext instance Makes debugging wonky state a little nicer --- qemu/translate-all.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qemu/translate-all.c b/qemu/translate-all.c index f171f231..a14388ba 100644 --- a/qemu/translate-all.c +++ b/qemu/translate-all.c @@ -167,7 +167,7 @@ static void page_table_config_init(struct uc_struct *uc) static void cpu_gen_init(struct uc_struct *uc) { - uc->tcg_ctx = g_malloc(sizeof(TCGContext)); + uc->tcg_ctx = g_malloc0(sizeof(TCGContext)); tcg_context_init(uc->tcg_ctx); }