From: Dan Carpenter <dan.carpenter@oracle.com>
To: Kees Cook <keescook@chromium.org>
Cc: Wei Yongjun <weiyj.lk@gmail.com>,
Al Viro <viro@zeniv.linux.org.uk>,
"Eric W. Biederman" <ebiederm@xmission.com>,
Serge Hallyn <serge.hallyn@canonical.com>,
yongjun_wei@trendmicro.com.cn,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] befs: fix return value check in befs_iget()
Date: Wed, 30 Oct 2013 21:29:02 +0300 [thread overview]
Message-ID: <20131030182902.GK20521@mwanda> (raw)
In-Reply-To: <CAGXu5jKRTv_xW1kbPBR+GYNDvPTb5rirFXNZjGH17Rsssh8q4A@mail.gmail.com>
On Wed, Oct 30, 2013 at 10:52:38AM -0700, Kees Cook wrote:
> On Mon, Oct 28, 2013 at 7:00 PM, Wei Yongjun <weiyj.lk@gmail.com> wrote:
> > From: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
> >
> > In case of error, the function iget_locked() returns NULL pointer
> > not ERR_PTR(). The IS_ERR() test in the return value check should
> > be replaced with NULL test.
> >
> > Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn>
>
> Good catch, thanks!
>
> Acked-by: Kees Cook <keescook@chromium.org>
>
> As an aside, Dan, how hard would this kind of mismatch be to detect
> with smatch?
It already does, but you need the cross function database set up.
regards,
dan carpenter
prev parent reply other threads:[~2013-10-30 18:29 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-29 2:00 [PATCH] befs: fix return value check in befs_iget() Wei Yongjun
2013-10-29 15:09 ` Serge E. Hallyn
2013-10-30 17:52 ` Kees Cook
2013-10-30 18:29 ` Dan Carpenter [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=20131030182902.GK20521@mwanda \
--to=dan.carpenter@oracle.com \
--cc=ebiederm@xmission.com \
--cc=keescook@chromium.org \
--cc=linux-kernel@vger.kernel.org \
--cc=serge.hallyn@canonical.com \
--cc=viro@zeniv.linux.org.uk \
--cc=weiyj.lk@gmail.com \
--cc=yongjun_wei@trendmicro.com.cn \
/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