From: Dan Carpenter Date: Fri, 12 Jul 2024 14:07:36 +0000 (-0500) Subject: xfs: remove unnecessary check X-Git-Tag: xfs-zoned-2024-21-07~522^2~8 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=fb8b941c75bd70ddfb0a8a3bb9bb770ed1d648f8;p=users%2Fhch%2Fxfs.git xfs: remove unnecessary check We checked that "pip" is non-NULL at the start of the if else statement so there is no need to check again here. Delete the check. Signed-off-by: Dan Carpenter Reviewed-by: Darrick J. Wong Reviewed-by: Chaitanya Kulkarni Signed-off-by: Chandan Babu R --- diff --git a/fs/xfs/libxfs/xfs_inode_util.c b/fs/xfs/libxfs/xfs_inode_util.c index 032333289113..cc38e1c3c3e1 100644 --- a/fs/xfs/libxfs/xfs_inode_util.c +++ b/fs/xfs/libxfs/xfs_inode_util.c @@ -308,7 +308,7 @@ xfs_inode_init( !vfsgid_in_group_p(i_gid_into_vfsgid(args->idmap, inode))) inode->i_mode &= ~S_ISGID; - ip->i_projid = pip ? xfs_get_initial_prid(pip) : 0; + ip->i_projid = xfs_get_initial_prid(pip); } ip->i_disk_size = 0;