]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
vfs_streams_xattr: remove fsp argument from get_xattr_size()
authorRalph Boehme <slow@samba.org>
Thu, 11 May 2017 15:36:15 +0000 (17:36 +0200)
committerKarolin Seeger <kseeger@samba.org>
Mon, 14 Aug 2017 08:50:10 +0000 (10:50 +0200)
Still in the process of changing all handle based operations to use path
based operations.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=12791

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Richard Sharpe <realrichardsharpe@gmail.com>
Reviewed-by: Volker Lendecke <vl@samba.org>
(backported from commit 4cc59e6d011cd3804499ba82bb4071973aa9d494)

source3/modules/vfs_streams_xattr.c

index fafbe585947344e68d773e40e5891349e79e1141..c1b6b7db56a67d679963307a68d3f3be2ba1d70b 100644 (file)
@@ -77,7 +77,6 @@ static SMB_INO_T stream_inode(const SMB_STRUCT_STAT *sbuf, const char *sname)
 }
 
 static ssize_t get_xattr_size(connection_struct *conn,
-                               files_struct *fsp,
                                const char *fname,
                                const char *xattr_name)
 {
@@ -85,7 +84,7 @@ static ssize_t get_xattr_size(connection_struct *conn,
        struct ea_struct ea;
        ssize_t result;
 
-       status = get_ea_value(talloc_tos(), conn, fsp, fname,
+       status = get_ea_value(talloc_tos(), conn, NULL, fname,
                              xattr_name, &ea);
 
        if (!NT_STATUS_IS_OK(status)) {
@@ -264,7 +263,7 @@ static int streams_xattr_fstat(vfs_handle_struct *handle, files_struct *fsp,
                return -1;
        }
 
-       sbuf->st_ex_size = get_xattr_size(handle->conn, fsp,
+       sbuf->st_ex_size = get_xattr_size(handle->conn,
                                        io->base, io->xattr_name);
        if (sbuf->st_ex_size == -1) {
                SET_STAT_INVALID(*sbuf);
@@ -316,7 +315,7 @@ static int streams_xattr_stat(vfs_handle_struct *handle,
        }
 
        /* Augment the base file's stat information before returning. */
-       smb_fname->st.st_ex_size = get_xattr_size(handle->conn, NULL,
+       smb_fname->st.st_ex_size = get_xattr_size(handle->conn,
                                                  smb_fname->base_name,
                                                  xattr_name);
        if (smb_fname->st.st_ex_size == -1) {
@@ -368,7 +367,7 @@ static int streams_xattr_lstat(vfs_handle_struct *handle,
        }
 
        /* Augment the base file's stat information before returning. */
-       smb_fname->st.st_ex_size = get_xattr_size(handle->conn, NULL,
+       smb_fname->st.st_ex_size = get_xattr_size(handle->conn,
                                                  smb_fname->base_name,
                                                  xattr_name);
        if (smb_fname->st.st_ex_size == -1) {