From patchwork Mon May 25 07:14:37 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shannon Zhao X-Patchwork-Id: 48948 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f72.google.com (mail-la0-f72.google.com [209.85.215.72]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 62E7B21411 for ; Mon, 25 May 2015 07:22:15 +0000 (UTC) Received: by lagv1 with SMTP id v1sf19735197lag.1 for ; Mon, 25 May 2015 00:22:14 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:date:message-id :mime-version:content-type:cc:subject:precedence:list-id :list-unsubscribe:list-archive:list-post:list-help:list-subscribe :errors-to:sender:x-original-sender :x-original-authentication-results:mailing-list; bh=Ye1PpS0lA9vDR/VfyXjFfJ+KvSr9J0UYqP7VNbeqYMo=; b=CrjDW0dOtEhny9fAfEztMpXHe5mPtzi8cPLT3WuybeE3Zp/vbXz3eSa3OrceNwDktS OQA522mWy0MrXBC1ADe6zecRERy/raEy1fNorYFD8BFKL69nyqLPxIy4Bic/RsDO0lpZ lu/SNzchjQz0DWxExoQgbblQbr8gkNe6i70ilR3tRghDDIRORU9fWnQDHKz7HJzi+hEg 1vgzHNLrDP0u0lNN68362jmQxng+wC2fjilWH/6q15+hlVYnRIhAp32OVQv6sGndufnL pvfYrfvj3Yt178qctIP6tRk6y/UlAcAfS5/080xaWuyEp7MhpqzZyiIGiZfSqNOtGEhS 8Oow== X-Gm-Message-State: ALoCoQkgjCnlYqLGkpJwx2UGC7b6dCAclbTlH4y1uEkciVDFewuEHuyZsaCqgwCM8QmVBexjv7RX X-Received: by 10.194.202.229 with SMTP id kl5mr21016259wjc.3.1432538534314; Mon, 25 May 2015 00:22:14 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.179.39 with SMTP id dd7ls749075lac.60.gmail; Mon, 25 May 2015 00:22:14 -0700 (PDT) X-Received: by 10.152.197.2 with SMTP id iq2mr17243697lac.103.1432538534182; Mon, 25 May 2015 00:22:14 -0700 (PDT) Received: from mail-lb0-f170.google.com (mail-lb0-f170.google.com. [209.85.217.170]) by mx.google.com with ESMTPS id wd2si7766792lbb.123.2015.05.25.00.22.14 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 25 May 2015 00:22:14 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.170 as permitted sender) client-ip=209.85.217.170; Received: by lbbqq2 with SMTP id qq2so46446492lbb.3 for ; Mon, 25 May 2015 00:22:14 -0700 (PDT) X-Received: by 10.152.36.161 with SMTP id r1mr17133084laj.88.1432538534061; Mon, 25 May 2015 00:22:14 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.108.230 with SMTP id hn6csp1655066lbb; Mon, 25 May 2015 00:22:13 -0700 (PDT) X-Received: by 10.55.40.42 with SMTP id o42mr42692376qkh.73.1432538532911; Mon, 25 May 2015 00:22:12 -0700 (PDT) Received: from lists.gnu.org (lists.gnu.org. [2001:4830:134:3::11]) by mx.google.com with ESMTPS id o2si4983299qci.22.2015.05.25.00.22.12 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Mon, 25 May 2015 00:22:12 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 2001:4830:134:3::11 as permitted sender) client-ip=2001:4830:134:3::11; Received: from localhost ([::1]:42248 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YwmiC-0003Jb-3J for patch@linaro.org; Mon, 25 May 2015 03:22:12 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:54844) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ywmhj-0002s5-Be for qemu-devel@nongnu.org; Mon, 25 May 2015 03:21:47 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Ywmhf-00029u-JC for qemu-devel@nongnu.org; Mon, 25 May 2015 03:21:43 -0400 Received: from szxga03-in.huawei.com ([119.145.14.66]:47060) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ywmhf-00028m-0h for qemu-devel@nongnu.org; Mon, 25 May 2015 03:21:39 -0400 Received: from 172.24.2.119 (EHLO szxeml432-hub.china.huawei.com) ([172.24.2.119]) by szxrg03-dlp.huawei.com (MOS 4.4.3-GA FastPath queued) with ESMTP id BGN01877; Mon, 25 May 2015 15:15:12 +0800 (CST) Received: from HGHY1Z002260041.china.huawei.com (10.177.16.142) by szxeml432-hub.china.huawei.com (10.82.67.209) with Microsoft SMTP Server id 14.3.158.1; Mon, 25 May 2015 15:14:44 +0800 From: Shannon Zhao To: , , Date: Mon, 25 May 2015 15:14:37 +0800 Message-ID: <1432538077-15712-1-git-send-email-zhaoshenglong@huawei.com> X-Mailer: git-send-email 1.9.0.msysgit.0 MIME-Version: 1.0 X-Originating-IP: [10.177.16.142] X-CFilter-Loop: Reflected X-Mirapoint-Virus-RAPID-Raw: score=unknown(0), refid=str=0001.0A020203.5562CC01.0098, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0, ip=0.0.0.0, so=2013-05-26 15:14:31, dmn=2013-03-21 17:37:32 X-Mirapoint-Loop-Id: 6358ba386f10a084bc571196f973dadd X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 119.145.14.66 Cc: shannon.zhao@linaro.org Subject: [Qemu-devel] [PATCH] hw/acpi/aml-build: Fix memory leak X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: , List-Help: , List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: patch@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.170 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 From: Shannon Zhao Signed-off-by: Shannon Zhao Signed-off-by: Shannon Zhao --- hw/acpi/aml-build.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/acpi/aml-build.c b/hw/acpi/aml-build.c index 323b7bc..9efef70 100644 --- a/hw/acpi/aml-build.c +++ b/hw/acpi/aml-build.c @@ -306,6 +306,7 @@ static void aml_free(gpointer data, gpointer user_data) { Aml *var = data; build_free_array(var->buf); + g_free(var); } Aml *init_aml_allocator(void)