lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190529155419.ego3sfedew65ini5@dev.nikanor.nu>
Date:   Wed, 29 May 2019 17:54:19 +0200
From:   Simon Sandström <simon@...anor.nu>
To:     Dan Carpenter <dan.carpenter@...cle.com>
Cc:     gregkh@...uxfoundation.org, devel@...verdev.osuosl.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH 3/4] staging: kpc2000: add missing spaces in core.c

On Mon, May 27, 2019 at 10:31:59AM +0300, Dan Carpenter wrote:
> On Fri, May 24, 2019 at 01:08:01PM +0200, Simon Sandström wrote:
> > [..]
> > -		ret = copy_to_user((void*)ioctl_param, (void*)&temp, sizeof(temp));
> > +		ret = copy_to_user((void *)ioctl_param, (void *)&temp, sizeof(temp));
> >  		if (ret)
> >  			return -EFAULT;
> 
> This should really be written like so:
> 
> 		if (copy_to_user((void __user *)ioctl_param, &temp,
> 				 sizeof(temp)))
> 			return -EFAULT;
> 
> temp is really the wrong name.  "temp" is for temperatures.  "tmp" means
> temporary.  But also "tmp" is wrong here because it's not a temporary
> variable.  It's better to call it "regs" here.
> 
> regards,
> dan carpenter
> 

I agree, but I don't think it fits within this patch. I can send a
separate patch with this change.

Thanks

- Simon

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ