From patchwork Fri Nov 16 06:47:32 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: free the memory malloced by load_at() Date: Thu, 15 Nov 2012 20:47:32 -0000 From: Olivia Yin X-Patchwork-Id: 199501 Message-Id: <1353048452-27338-1-git-send-email-hong-hua.yin@freescale.com> To: , Cc: Olivia Yin Signed-off-by: Olivia Yin --- hw/elf_ops.h | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/hw/elf_ops.h b/hw/elf_ops.h index db4630e..4495932 100644 --- a/hw/elf_ops.h +++ b/hw/elf_ops.h @@ -178,6 +178,8 @@ static int glue(load_symbols, SZ)(struct elfhdr *ehdr, int fd, int must_swab, s->disas_strtab = str; s->next = syminfos; syminfos = s; + g_free(syms); + g_free(str); g_free(shdr_table); return 0; fail: