From: Fengguang Wu <fengguang.wu@intel.com>
To: "devendra.aaru" <devendra.aaru@gmail.com>
Cc: Anton Altaparmakov <anton@tuxera.com>,
kernel-janitors@vger.kernel.org,
linux-ntfs-dev@lists.sourceforge.net,
linux-kernel@vger.kernel.org
Subject: Re: fs/ntfs/super.c:2717:1-14: alloc with no test
Date: Sun, 26 Aug 2012 17:31:13 +0800 [thread overview]
Message-ID: <20120826093113.GA11809@localhost> (raw)
In-Reply-To: <CAHdPZaNs99QLOD=-QeUvFj5soSJMZCPU24V=5QXuVWx0r1jC5g@mail.gmail.com>
On Sun, Aug 26, 2012 at 02:42:12PM +0530, devendra.aaru wrote:
> On Sun, Aug 26, 2012 at 2:34 PM, Fengguang Wu <fengguang.wu@intel.com> wrote:
> >
> > Hi Anton,
> >
> > FYI, coccinelle warns about
> >
> > fs/ntfs/super.c:2717:1-14: alloc with no test, possible model on line 2718
> >
> > vim +2717 fs/ntfs/super.c
> > 2714 sb->s_flags |= MS_RDONLY;
> > 2715 #endif /* ! NTFS_RW */
> > 2716 /* Allocate a new ntfs_volume and place it in sb->s_fs_info. */
> >> 2717 sb->s_fs_info = kmalloc(sizeof(ntfs_volume), GFP_NOFS);
>
> That's i think a false alarm.
>
> > 2718 vol = NTFS_SB(sb);
>
> The NTFS_SB(buf) {
> buf->s_fs_info;
> }
>
> so we are validating the allocated pointer s_fs_info.
Yes, it is. Sorry for the noise!
Thanks,
Fengguang
prev parent reply other threads:[~2012-08-26 9:31 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-26 9:04 fs/ntfs/super.c:2717:1-14: alloc with no test Fengguang Wu
2012-08-26 9:12 ` devendra.aaru
2012-08-26 9:31 ` Fengguang Wu [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=20120826093113.GA11809@localhost \
--to=fengguang.wu@intel.com \
--cc=anton@tuxera.com \
--cc=devendra.aaru@gmail.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-ntfs-dev@lists.sourceforge.net \
/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