Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp1095227pxj; Fri, 4 Jun 2021 06:05:00 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx7O0bQIyhcTpiGv58Pu3u7EgJMeCIm6SNS9+pCRzg/kA++35aquR5BlmDz2pBFuGkzt3Cs X-Received: by 2002:adf:8b91:: with SMTP id o17mr3739484wra.385.1622811900615; Fri, 04 Jun 2021 06:05:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622811900; cv=none; d=google.com; s=arc-20160816; b=Wt+6uVH24HKLFXLCdPMKCPArUvoEw9dT3X7oc51EbQJZI8wA0TOhLa+gdztjmrxEcU xtxbUVWdEiThYd8QoGqSSS/47rpAMOTzWvsE71zSG+NNmk6VEDvpHCVMr/H6eKZz3QtP GaxSN9h6KIxTBE8OG8q0J2net7zzmbIUZn1LH9bZN+RLTNuK9FdQJZ2xGdJyqQGBjbmR TCAMv+Cs9Sc7W8TPSVNDN8Fk4G94aSrErTi/twn21WVz235FkXGSDeR5no32qBfLGyZh VyC8+e4SW4RiZkfAIoFL7MvizE5IRuTBMKrP3WbTG7kOhHad6DckjBY0McKoYiNHPxBT duYg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=xO0vWvUcWa9hzOpwk7YhZZmrkQRgQmGYYr2kTaIyxCo=; b=MoxoBcwhEAfvh4VQPjof5o6P1IJgxUfes555YJh0EpjkYJinVt8jqF0ULP5313MVG9 Y58NbkTLxI/Ydr0YjC6GyKzNmlfdP1Js+wgjSMvAM75N6JqdhBRmXz1LkrWN6NtCiR54 l2qQSWLzzmc/82CxxxvT6ky0CG+yI+EB5VSo4l8Vl2vMSW+N8B5oSRYwESyCQRcgb/Tg 8Qrban8tBcxlxyppHPno1jXLR5drONXYWMPM76GWcTA7D56rxNVp1xrb3tOPovWQxeYn YrtmmLtb/Ib2Au12LUmUNaiqZq8cFa/bhfHCvu9BFwj0e96BfC761uUsPcJRoES4PBUZ 6c8A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=nONJ9Ao2; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ga2si4722322ejb.249.2021.06.04.06.04.33; Fri, 04 Jun 2021 06:05:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=nONJ9Ao2; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230193AbhFDNCm (ORCPT + 99 others); Fri, 4 Jun 2021 09:02:42 -0400 Received: from mail.kernel.org ([198.145.29.99]:44196 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230004AbhFDNCm (ORCPT ); Fri, 4 Jun 2021 09:02:42 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 5391D61107; Fri, 4 Jun 2021 13:00:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1622811656; bh=BJsetL4SUhorJv06M9mPfb8Edmqe8ztcraguJgIeMRE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=nONJ9Ao2Qnhn7thGdWURRYH2mLumcjw0Z0R0G/BxnMmhcJmxASwKknGifiVp/G669 AFqa9tz4p5ZfTsvBWpEjyQRatGY/ZtT2P6UmuTi9gsiE3XotB/CczQcxZFWkCVKcyR EsIlOvTDR4Bcaqu+rCZKTZUCFR1iVqbtEN/OK/kIObBAr6TWJKDboi2H+aKuplflt3 D9WDnp8QH5HdjEH5e7YSENADifOagK/CKMNlTsdGpLDKuGdxJIkDeU7Mxe5UHcChI6 gEGf65cpmb4dWC5QWP7GAFzVqTwVmKf/CiaGCwu8Aj2BDKACnyqenEyl14j8PNyy9u GK0ieD3FBA7Vw== Received: by quaco.ghostprotocols.net (Postfix, from userid 1000) id 07D0A40EFC; Fri, 4 Jun 2021 10:00:52 -0300 (-03) Date: Fri, 4 Jun 2021 10:00:52 -0300 From: Arnaldo Carvalho de Melo To: Ian Rogers Cc: Riccardo Mancini , Namhyung Kim , Peter Zijlstra , Ingo Molnar , Mark Rutland , Alexander Shishkin , Jiri Olsa , Fabian Hemmer , Remi Bernon , Jiri Slaby , linux-perf-users , LKML Subject: Re: [PATCH] perf symbol-elf: fix memory leak: free sdt_note.args Message-ID: References: <20210602220833.285226-1-rickyman7@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Url: http://acmel.wordpress.com Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Em Thu, Jun 03, 2021 at 09:08:46PM -0700, Ian Rogers escreveu: > On Wed, Jun 2, 2021 at 3:12 PM Riccardo Mancini wrote: > > > > Reported by ASan. > > Did you have a reproducer for getting this to fail? > > > Signed-off-by: Riccardo Mancini > > Acked-by: Ian Rogers Thanks, applied. - Arnaldo > Thanks, > Ian > > > --- > > tools/perf/util/symbol-elf.c | 1 + > > 1 file changed, 1 insertion(+) > > > > diff --git a/tools/perf/util/symbol-elf.c b/tools/perf/util/symbol-elf.c > > index 4c56aa8374344..a73345730ba90 100644 > > --- a/tools/perf/util/symbol-elf.c > > +++ b/tools/perf/util/symbol-elf.c > > @@ -2412,6 +2412,7 @@ int cleanup_sdt_note_list(struct list_head *sdt_notes) > > > > list_for_each_entry_safe(pos, tmp, sdt_notes, note_list) { > > list_del_init(&pos->note_list); > > + zfree(&pos->args); > > zfree(&pos->name); > > zfree(&pos->provider); > > free(pos); > > -- > > 2.31.1 > > -- - Arnaldo