DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Burakov, Anatoly" <anatoly.burakov@intel.com>
To: Thomas Monjalon <thomas@monjalon.net>,
	Yangchao Zhou <zhouyates@gmail.com>
Cc: dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH v3] mem: fix memory leaks of hugedir and replace snprintf
Date: Wed, 18 Apr 2018 10:25:32 +0100	[thread overview]
Message-ID: <6ceb0baf-10f8-f501-54d2-1e3668db0fcb@intel.com> (raw)
In-Reply-To: <2393278.IC1XLxtKtA@xps>

On 18-Apr-18 10:00 AM, Thomas Monjalon wrote:
> 18/04/2018 05:09, Yangchao Zhou:
>> The hugedir returned by get_hugepage_dir is allocated by strdup
>>   but not released. Replace snprintf with a more suitable strlcpy.
>>
>> Coverity issue: 272585
>> Fixes: cb97d93e9d3b ("mem: share hugepage info primary and secondary")
>>
>> Signed-off-by: Yangchao Zhou <zhouyates@gmail.com>
>> Acked-by: Anatoly Burakov <anatoly.burakov@intel.com>
> 
> There was a misunderstanding.
> You replaced some snprintf which were not involved in the leaks.
> But I think it's fine.
> 
> Applied, thanks
> 

I'll check to see if i have to rebase my strlcpy patchset.

-- 
Thanks,
Anatoly

      reply	other threads:[~2018-04-18  9:25 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-17  9:43 [dpdk-dev] [PATCH] mem: memory leaks of hubedir caused by strdup Yangchao Zhou
2018-04-17  9:57 ` Burakov, Anatoly
2018-04-17 10:06   ` [dpdk-dev] [PATCH v2] " Yangchao Zhou
2018-04-17 10:24     ` Thomas Monjalon
2018-04-17 10:31       ` Burakov, Anatoly
2018-04-17 11:16         ` zhouyangchao
2018-04-17 11:47           ` Thomas Monjalon
2018-04-17 14:02             ` Burakov, Anatoly
2018-04-18  3:09               ` [dpdk-dev] [PATCH v3] mem: fix memory leaks of hugedir and replace snprintf Yangchao Zhou
2018-04-18  9:00                 ` Thomas Monjalon
2018-04-18  9:25                   ` Burakov, Anatoly [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6ceb0baf-10f8-f501-54d2-1e3668db0fcb@intel.com \
    --to=anatoly.burakov@intel.com \
    --cc=dev@dpdk.org \
    --cc=thomas@monjalon.net \
    --cc=zhouyates@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).