From: Andrew Morton <akpm@linux-foundation.org>
To: Ryan Cai <ycaibb@gmail.com>
Cc: <shuah@kernel.org>, <linux-mm@kvack.org>,
<linux-kselftest@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [Resource Leak] Missing closing files in testing/selftests/vm/mlock2
Date: Wed, 29 Dec 2021 19:51:35 -0800 [thread overview]
Message-ID: <20211229195135.959b3730c54652de497e932b@linux-foundation.org> (raw)
In-Reply-To: <C8980E43-5BED-45C6-B3F8-7BC3D58DF21A@gmail.com>
On Thu, 30 Dec 2021 11:17:37 +0800 Ryan Cai <ycaibb@gmail.com> wrote:
> Dear Kernel maintainers,
> 1. In testing/selftests/vm/mlock2, the file opened at Line 39 may not closed when going to Line 65.
> Location: https://github.com/torvalds/linux/blob/5bfc75d92efd494db37f5c4c173d3639d4772966/tools/testing/selftests/vm/mlock2.h#L37-L49
That's what exit() does. I don't think we really care unless the leak
is inside a loop.
That being said, it's untidy and is setting a poor example so I guess
we should fix it.
> Can I send I a patch?
It would be better to just send the patch rather than preceding it
with "can I send a patch". Everyone can send a patch and they are
encouraged to do so!
prev parent reply other threads:[~2021-12-30 3:51 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-12-30 3:17 Ryan Cai
2021-12-30 3:51 ` Andrew Morton [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=20211229195135.959b3730c54652de497e932b@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=shuah@kernel.org \
--cc=ycaibb@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