Re: [PATCH] mkfs.xfs: annotate fallthrough cases in cvtnum

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

 



On Wed, May 11, 2016 at 09:47:45PM -0500, Eric Sandeen wrote:
> We should really collapse our 3 cvtnum variants,
> but for now at least shut up Coverity about this
> intentional case fallthrough.
> 

Looks good

Reviewed-by: Carlos Maiolino <cmaiolino@xxxxxxxxxx>

> Addresses-Coverity-ID: 1361553
> Addresses-Coverity-ID: 1361554
> Addresses-Coverity-ID: 1361555
> Addresses-Coverity-ID: 1361556
> Signed-off-by: Eric Sandeen <sandeen@xxxxxxxxxx>
> ---
> 
> diff --git a/mkfs/xfs_mkfs.c b/mkfs/xfs_mkfs.c
> index 955dcfd..12fe8f3 100644
> --- a/mkfs/xfs_mkfs.c
> +++ b/mkfs/xfs_mkfs.c
> @@ -3623,14 +3623,19 @@ cvtnum(
>  	switch (c) {
>  	case 'e':
>  		i *= 1024LL;
> +		/* fall through */
>  	case 'p':
>  		i *= 1024LL;
> +		/* fall through */
>  	case 't':
>  		i *= 1024LL;
> +		/* fall through */
>  	case 'g':
>  		i *= 1024LL;
> +		/* fall through */
>  	case 'm':
>  		i *= 1024LL;
> +		/* fall through */
>  	case 'k':
>  		return i * 1024LL;
>  	default:
> 
> _______________________________________________
> xfs mailing list
> xfs@xxxxxxxxxxx
> http://oss.sgi.com/mailman/listinfo/xfs

-- 
Carlos

_______________________________________________
xfs mailing list
xfs@xxxxxxxxxxx
http://oss.sgi.com/mailman/listinfo/xfs



[Index of Archives]     [Linux XFS Devel]     [Linux Filesystem Development]     [Filesystem Testing]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux