From: Greg KH <greg@kroah.com>
To: LKML <linux-kernel@vger.kernel.org>
Cc: Stefan Eletzhofer <Stefan.Eletzhofer@eletztrick.de>
Subject: Re: [PATCH 2.6] Remove NULL client checks in rtc8564 driver
Date: Fri, 25 Feb 2005 12:07:30 -0800 [thread overview]
Message-ID: <20050225200729.GA25915@kroah.com> (raw)
In-Reply-To: <20050224224957.278cdcd8.khali@linux-fr.org>
On Thu, Feb 24, 2005 at 10:49:57PM +0100, Jean Delvare wrote:
> Hi Stefan,
>
> Several functions in your rtc8564 driver verify the non-NULLity of the
> i2c client that is passed to them. It doesn't seem to be necessary, as I
> can't think of any case where these functions could possibly be called
> with a NULL i2c client. As a matter of fact, I couldn't find any similar
> driver doing such checks.
>
> My attention was brought on this by Coverity's SWAT which correctly
> noticed that three of these functions contain explicit or hidden
> dereferences of the i2c client pointer *before* the NULL check. I guess
> it wasn't a problem because the NULL case cannot happen (unless I miss
> something), but this still is confusing code.
>
> Thus I propose the following changes:
Applied, thanks.
greg k-h
prev parent reply other threads:[~2005-02-25 20:08 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-02-24 21:49 [PATCH 2.6] Remove NULL client checks in rtc8564 driver Jean Delvare
2005-02-25 20:07 ` Greg KH [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=20050225200729.GA25915@kroah.com \
--to=greg@kroah.com \
--cc=Stefan.Eletzhofer@eletztrick.de \
--cc=linux-kernel@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.