From: Kirill Tkhai <ktkhai@virtuozzo.com>
To: cgxu519 <cgxu519@gmx.com>, davem@davemloft.net
Cc: keescook@chromium.org, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH net] netlink: fix a memory leak on error path
Date: Mon, 25 Mar 2019 11:12:45 +0300 [thread overview]
Message-ID: <84e65ccd-d2ee-ed7c-e758-06a8a74312e3@virtuozzo.com> (raw)
In-Reply-To: <786f1aec-fe47-f060-6f6e-4307ecaff82d@gmx.com>
On 25.03.2019 04:19, cgxu519 wrote:
> On 3/22/19 7:03 PM, Kirill Tkhai wrote:
>> Hi, Chengguang,
>>
>> On 22.03.2019 13:58, Chengguang Xu wrote:
>>> In genl_register_family(), when idr_alloc() fails,
>>> we forget to free family->attrbuf.
>>>
>>> Note, some callers call genl_unregister_family() to clean up
>>> on error path, it doesn't work because the family is inserted
>>> to the global list in the nearly last step.
>>>
>>> Fixes: 2ae0f17df1c ("genetlink: use idr to track families").
>>> Signed-off-by: Chengguang Xu <cgxu519@gmx.com>
>> have you seen https://patchwork.ozlabs.org/patch/1059834/ ?
>
> Sorry, I didn't notice that because I'm mainly working on linus-tree.
> Please just ignore this patch.
Not a problem.
Some information about network development process you may find in
https://www.kernel.org/doc/Documentation/networking/netdev-FAQ.txt
Kirill
prev parent reply other threads:[~2019-03-25 8:12 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-22 10:58 [PATCH net] netlink: fix a memory leak on error path Chengguang Xu
2019-03-22 11:03 ` Kirill Tkhai
2019-03-25 1:19 ` cgxu519
2019-03-25 8:12 ` Kirill Tkhai [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=84e65ccd-d2ee-ed7c-e758-06a8a74312e3@virtuozzo.com \
--to=ktkhai@virtuozzo.com \
--cc=cgxu519@gmx.com \
--cc=davem@davemloft.net \
--cc=keescook@chromium.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
/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).