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] [day] [month] [year] [list]
Message-ID: <20180112164738.GW5602@magnolia>
Date:   Fri, 12 Jan 2018 08:47:38 -0800
From:   "Darrick J. Wong" <darrick.wong@...cle.com>
To:     Colin King <colin.king@...onical.com>
Cc:     linux-xfs@...r.kernel.org, Brian Foster <bfoster@...hat.com>,
        Dave Chinner <dchinner@...hat.com>,
        Eric Sandeen <sandeen@...hat.com>,
        kernel-janitors@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH][xfs-next] xfs: fix check on struct_version for versions
 4 or greater

On Fri, Jan 12, 2018 at 04:37:15PM +0000, Colin King wrote:
> From: Colin Ian King <colin.king@...onical.com>
> 
> It appears that the check for versions 4 or more is incorrect and is
> off-by-one. Fix this.
> 
> Detected by CoverityScan, CID#1463775 ("Logically dead code")
> 
> Fixes: ac503a4cc9e8 ("xfs: refactor the geometry structure filling function")
> Signed-off-by: Colin Ian King <colin.king@...onical.com>

Looks ok,
Reviewed-by: Darrick J. Wong <darrick.wong@...cle.com>

> ---
>  fs/xfs/libxfs/xfs_sb.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/fs/xfs/libxfs/xfs_sb.c b/fs/xfs/libxfs/xfs_sb.c
> index 35b005d66977..869a2f3f0375 100644
> --- a/fs/xfs/libxfs/xfs_sb.c
> +++ b/fs/xfs/libxfs/xfs_sb.c
> @@ -951,7 +951,7 @@ xfs_fs_geometry(
>  	geo->rtsectsize = sbp->sb_blocksize;
>  	geo->dirblocksize = xfs_dir2_dirblock_bytes(sbp);
>  
> -	if (struct_version < 3)
> +	if (struct_version < 4)
>  		return 0;
>  
>  	if (xfs_sb_version_haslogv2(sbp))
> -- 
> 2.15.1
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-xfs" in
> the body of a message to majordomo@...r.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ