]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3: VFS: streams_xattr: In streams_xattr_ftruncate() - remove conditional.
authorJeremy Allison <jra@samba.org>
Wed, 23 Jun 2021 00:36:28 +0000 (17:36 -0700)
committerRalph Boehme <slow@samba.org>
Fri, 25 Jun 2021 15:53:31 +0000 (15:53 +0000)
We know fsp->base_fsp must be valid here for SMB_VFS_FSETXATTR()

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
source3/modules/vfs_streams_xattr.c

index 677d33483641238c653910de304cce6176fb1e71..780b0d76d265bfc45c12dc96ae8974a28ad557e0 100644 (file)
@@ -1305,9 +1305,11 @@ static int streams_xattr_ftruncate(struct vfs_handle_struct *handle,
        ea.value.length = offset + 1;
        ea.value.data[offset] = 0;
 
-       ret = SMB_VFS_FSETXATTR(fsp->base_fsp ? fsp->base_fsp : fsp,
-                              sio->xattr_name,
-                              ea.value.data, ea.value.length, 0);
+       ret = SMB_VFS_FSETXATTR(fsp->base_fsp,
+                               sio->xattr_name,
+                               ea.value.data,
+                               ea.value.length,
+                               0);
 
        TALLOC_FREE(ea.value.data);