Re: [PATCH][next] block: scsi_ioctl: Avoid the use of one-element arrays

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

 



On Fri, Oct 02, 2020 at 05:58:33PM -0600, Jens Axboe wrote:
> >>> -	void			__user *reserved[1];	/* unused, actually */
> >>> +	union {
> >>> +		void		__user *reserved[1];	/* unused, actually */
> >>> +		void            __user *unused;
> >>> +	};
> >>
> >> What's the point of this union, why not just turn it into
> >>
> >> 	void *			__user *unused;
> >>
> >> ?
> > 
> > I just don't want to take any chances of breaking any user-space
> > application that, for some reason, may be considering that field.
> 
> I guess that's a valid concern, who knows what applications are doing
> to an ignored field.
> 
> I'll apply it, thanks.

Awesome. :)

Thanks.
--
Gustavo



[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux