From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Brownell Subject: Re: [patch 2.6.26-rc1] i2c_use_client() defends against NULL Date: Sat, 17 May 2008 06:57:56 -0700 Message-ID: <200805170657.56833.david-b@pacbell.net> References: <200805041306.21074.david-b@pacbell.net> <20080517144007.7611ab32@hyperion.delvare> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <20080517144007.7611ab32-ig7AzVSIIG7kN2dkZ6Wm7A@public.gmane.org> Content-Disposition: inline List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: i2c-bounces-GZX6beZjE8VD60Wz+7aTrA@public.gmane.org Errors-To: i2c-bounces-GZX6beZjE8VD60Wz+7aTrA@public.gmane.org To: Jean Delvare Cc: i2c-GZX6beZjE8VD60Wz+7aTrA@public.gmane.org List-Id: linux-i2c@vger.kernel.org On Saturday 17 May 2008, Jean Delvare wrote: > On Sun, 4 May 2008 13:06:20 -0700, David Brownell wrote: > > Defend the i2c refcount calls against NULL pointers, as is important > > (and conventional) for such calls ... we don't want to morph NULL > > pointers into bogus non-null ones. > > Passing NULL to the current functions would just crash, it wouldn't > morph anything. That's only if you assume an MMU set up to cause oopsing on reference to the first and last pages of memory. Not the best of assumptions... _______________________________________________ i2c mailing list i2c-GZX6beZjE8VD60Wz+7aTrA@public.gmane.org http://lists.lm-sensors.org/mailman/listinfo/i2c