Re: [patch v2] batman: cleanup: change test for end of array

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Mar 29, 2010 at 03:12:23PM +0800, Marek Lindner wrote:
> On Sunday 28 March 2010 21:13:35 Dan Carpenter wrote:
> > @@ -43,10 +43,7 @@ static struct device_client *device_client_hash[256];
> > 
> > -	for (i = 0; i < 256; i++)
> > -		device_client_hash[i] = NULL;
> > +	memset(&device_client_hash, 0, sizeof(device_client_hash));
> 
> I might be mistaken but it looks like the "&" is wrong here. Shouldn't it be:
> memset(device_client_hash, 0, sizeof(device_client_hash));

Either way works.

You can easily write a small test program to verify. :)

regards,
dan carpenter

> 
> Cheers,
> Marek
--
To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux