linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: NeilBrown <neilb@suse.de>
To: Adam Kwolek <adam.kwolek@intel.com>
Cc: linux-raid@vger.kernel.org, dan.j.williams@intel.com,
	ed.ciechanowski@intel.com, wojciech.neubauer@intel.com
Subject: Re: [PATCH 2/2] imsm: FIX: klocwork: passed dev pointer to is_gen_migration() can be NULL
Date: Tue, 14 Jun 2011 12:50:53 +1000	[thread overview]
Message-ID: <20110614125053.36e73b4e@notabene.brown> (raw)
In-Reply-To: <20110610155639.24539.67025.stgit@gklab-128-013.igk.intel.com>

On Fri, 10 Jun 2011 17:56:39 +0200 Adam Kwolek <adam.kwolek@intel.com> wrote:

> Pointer dev2 passed in write_super_imsm():4451 can be equal to NULL.
> 
> Signed-off-by: Adam Kwolek <adam.kwolek@intel.com>
> ---
> 
>  super-intel.c |    3 +++
>  1 files changed, 3 insertions(+), 0 deletions(-)
> 
> diff --git a/super-intel.c b/super-intel.c
> index 8dd0805..3b4010d 100644
> --- a/super-intel.c
> +++ b/super-intel.c
> @@ -5321,6 +5321,9 @@ static int update_subarray_imsm(struct supertype *st, char *subarray,
>  
>  static int is_gen_migration(struct imsm_dev *dev)
>  {
> +	if (dev == NULL)
> +		return 0;
> +
>  	if (!dev->vol.migr_state)
>  		return 0;
>  


Thanks.  I have applied this and most of the others you sent. 

NeilBrown


      reply	other threads:[~2011-06-14  2:50 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-10 15:56 [PATCH 0/2] IMSM Checkpointing Bug Fix Series (3) Adam Kwolek
2011-06-10 15:56 ` [PATCH 1/2] imsm: Fix: klocwork: targets variable can be used uninitialized Adam Kwolek
2011-06-10 15:56 ` [PATCH 2/2] imsm: FIX: klocwork: passed dev pointer to is_gen_migration() can be NULL Adam Kwolek
2011-06-14  2:50   ` NeilBrown [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=20110614125053.36e73b4e@notabene.brown \
    --to=neilb@suse.de \
    --cc=adam.kwolek@intel.com \
    --cc=dan.j.williams@intel.com \
    --cc=ed.ciechanowski@intel.com \
    --cc=linux-raid@vger.kernel.org \
    --cc=wojciech.neubauer@intel.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).