]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commitdiff
xfs: remove the name == NULL check from xfs_attr_args_init
authorChristoph Hellwig <hch@lst.de>
Wed, 29 Apr 2020 20:08:34 +0000 (16:08 -0400)
committerEric Sandeen <sandeen@redhat.com>
Wed, 29 Apr 2020 20:08:34 +0000 (16:08 -0400)
Source kernel commit: 79f2280b9bfd54aa37b3fa4a80b0037bd29b4f0e

All callers provide a valid name pointer, remove the redundant check.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Chandan Rajendra <chandanrlinux@gmail.com>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
libxfs/xfs_attr.c

index 248f9e8378a3ae10f189aeaac834591654cebe49..ee2225a30bb3a20d37f7a202531f50a1d05d9699 100644 (file)
@@ -65,10 +65,6 @@ xfs_attr_args_init(
        size_t                  namelen,
        int                     flags)
 {
-
-       if (!name)
-               return -EINVAL;
-
        memset(args, 0, sizeof(*args));
        args->geo = dp->i_mount->m_attr_geo;
        args->whichfork = XFS_ATTR_FORK;