diff options
author | Michael Adam <obnox@samba.org> | 2008-01-08 10:51:40 +0100 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2008-01-08 10:51:40 +0100 |
commit | 9f691df852581b1ae4fab7cb9907606f4dcab291 (patch) | |
tree | e7e7e8930ddc2c7ef5512228182d496774c268cd | |
parent | 50ee744fa445b74136a8f2cef36c2b48ba7ee5f6 (diff) | |
download | samba-9f691df852581b1ae4fab7cb9907606f4dcab291.tar.gz samba-9f691df852581b1ae4fab7cb9907606f4dcab291.tar.bz2 samba-9f691df852581b1ae4fab7cb9907606f4dcab291.zip |
Remove redundant parameter fd from SMB_VFS_FLISTXATTR().
Michael
(This used to be commit 167649b3b8bc293f8434ffc9fb5f80463e4e75be)
-rw-r--r-- | source3/include/vfs.h | 3 | ||||
-rw-r--r-- | source3/include/vfs_macros.h | 6 | ||||
-rw-r--r-- | source3/modules/vfs_default.c | 4 | ||||
-rw-r--r-- | source3/modules/vfs_full_audit.c | 6 | ||||
-rw-r--r-- | source3/smbd/trans2.c | 2 |
5 files changed, 11 insertions, 10 deletions
diff --git a/source3/include/vfs.h b/source3/include/vfs.h index 171f90f410..cf969a6d7a 100644 --- a/source3/include/vfs.h +++ b/source3/include/vfs.h @@ -95,6 +95,7 @@ /* Leave at 22 - not yet released. Remove parameter fd from fchmod_acl. - obnox */ /* Leave at 22 - not yet released. Remove parameter fd from sys_acl_set_fd. - obnox */ /* Leave at 22 - not yet released. Remove parameter fd from fgetxattr. - obnox */ +/* Leave at 22 - not yet released. Remove parameter fd from flistxattr. - obnox */ @@ -381,7 +382,7 @@ struct vfs_ops { ssize_t (*fgetxattr)(struct vfs_handle_struct *handle, struct files_struct *fsp, const char *name, void *value, size_t size); ssize_t (*listxattr)(struct vfs_handle_struct *handle, const char *path, char *list, size_t size); ssize_t (*llistxattr)(struct vfs_handle_struct *handle, const char *path, char *list, size_t size); - ssize_t (*flistxattr)(struct vfs_handle_struct *handle, struct files_struct *fsp,int fd, char *list, size_t size); + ssize_t (*flistxattr)(struct vfs_handle_struct *handle, struct files_struct *fsp, char *list, size_t size); int (*removexattr)(struct vfs_handle_struct *handle, const char *path, const char *name); int (*lremovexattr)(struct vfs_handle_struct *handle, const char *path, const char *name); int (*fremovexattr)(struct vfs_handle_struct *handle, struct files_struct *fsp,int filedes, const char *name); diff --git a/source3/include/vfs_macros.h b/source3/include/vfs_macros.h index 488d1792c0..64b30b253a 100644 --- a/source3/include/vfs_macros.h +++ b/source3/include/vfs_macros.h @@ -122,7 +122,7 @@ #define SMB_VFS_FGETXATTR(fsp,name,value,size) ((fsp)->conn->vfs.ops.fgetxattr((fsp)->conn->vfs.handles.fgetxattr,(fsp),(name),(value),(size))) #define SMB_VFS_LISTXATTR(conn,path,list,size) ((conn)->vfs.ops.listxattr((conn)->vfs.handles.listxattr,(path),(list),(size))) #define SMB_VFS_LLISTXATTR(conn,path,list,size) ((conn)->vfs.ops.llistxattr((conn)->vfs.handles.llistxattr,(path),(list),(size))) -#define SMB_VFS_FLISTXATTR(fsp,fd,list,size) ((fsp)->conn->vfs.ops.flistxattr((fsp)->conn->vfs.handles.flistxattr,(fsp),(fd),(list),(size))) +#define SMB_VFS_FLISTXATTR(fsp,list,size) ((fsp)->conn->vfs.ops.flistxattr((fsp)->conn->vfs.handles.flistxattr,(fsp),(list),(size))) #define SMB_VFS_REMOVEXATTR(conn,path,name) ((conn)->vfs.ops.removexattr((conn)->vfs.handles.removexattr,(path),(name))) #define SMB_VFS_LREMOVEXATTR(conn,path,name) ((conn)->vfs.ops.lremovexattr((conn)->vfs.handles.lremovexattr,(path),(name))) #define SMB_VFS_FREMOVEXATTR(fsp,fd,name) ((fsp)->conn->vfs.ops.fremovexattr((fsp)->conn->vfs.handles.fremovexattr,(fsp),(fd),(name))) @@ -241,7 +241,7 @@ #define SMB_VFS_OPAQUE_FGETXATTR(fsp,name,value,size) ((fsp)->conn->vfs_opaque.ops.fgetxattr((fsp)->conn->vfs_opaque.handles.fgetxattr,(fsp),(name),(value),(size))) #define SMB_VFS_OPAQUE_LISTXATTR(conn,path,list,size) ((conn)->vfs_opaque.ops.listxattr((conn)->vfs_opaque.handles.listxattr,(path),(list),(size))) #define SMB_VFS_OPAQUE_LLISTXATTR(conn,path,list,size) ((conn)->vfs_opaque.ops.llistxattr((conn)->vfs_opaque.handles.llistxattr,(path),(list),(size))) -#define SMB_VFS_OPAQUE_FLISTXATTR(fsp,fd,list,size) ((fsp)->conn->vfs_opaque.ops.flistxattr((fsp)->conn->vfs_opaque.handles.flistxattr,(fsp),(fd),(list),(size))) +#define SMB_VFS_OPAQUE_FLISTXATTR(fsp,list,size) ((fsp)->conn->vfs_opaque.ops.flistxattr((fsp)->conn->vfs_opaque.handles.flistxattr,(fsp),(list),(size))) #define SMB_VFS_OPAQUE_REMOVEXATTR(conn,path,name) ((conn)->vfs_opaque.ops.removexattr((conn)->vfs_opaque.handles.removexattr,(path),(name))) #define SMB_VFS_OPAQUE_LREMOVEXATTR(conn,path,name) ((conn)->vfs_opaque.ops.lremovexattr((conn)->vfs_opaque.handles.lremovexattr,(path),(name))) #define SMB_VFS_OPAQUE_FREMOVEXATTR(fsp,fd,name) ((fsp)->conn->vfs_opaque.ops.fremovexattr((fsp)->conn->vfs_opaque.handles.fremovexattr,(fsp),(fd),(name))) @@ -361,7 +361,7 @@ #define SMB_VFS_NEXT_FGETXATTR(handle,fsp,name,value,size) ((handle)->vfs_next.ops.fgetxattr((handle)->vfs_next.handles.fgetxattr,(fsp),(name),(value),(size))) #define SMB_VFS_NEXT_LISTXATTR(handle,path,list,size) ((handle)->vfs_next.ops.listxattr((handle)->vfs_next.handles.listxattr,(path),(list),(size))) #define SMB_VFS_NEXT_LLISTXATTR(handle,path,list,size) ((handle)->vfs_next.ops.llistxattr((handle)->vfs_next.handles.llistxattr,(path),(list),(size))) -#define SMB_VFS_NEXT_FLISTXATTR(handle,fsp,fd,list,size) ((handle)->vfs_next.ops.flistxattr((handle)->vfs_next.handles.flistxattr,(fsp),(fd),(list),(size))) +#define SMB_VFS_NEXT_FLISTXATTR(handle,fsp,list,size) ((handle)->vfs_next.ops.flistxattr((handle)->vfs_next.handles.flistxattr,(fsp),(list),(size))) #define SMB_VFS_NEXT_REMOVEXATTR(handle,path,name) ((handle)->vfs_next.ops.removexattr((handle)->vfs_next.handles.removexattr,(path),(name))) #define SMB_VFS_NEXT_LREMOVEXATTR(handle,path,name) ((handle)->vfs_next.ops.lremovexattr((handle)->vfs_next.handles.lremovexattr,(path),(name))) #define SMB_VFS_NEXT_FREMOVEXATTR(handle,fsp,fd,name) ((handle)->vfs_next.ops.fremovexattr((handle)->vfs_next.handles.fremovexattr,(fsp),(fd),(name))) diff --git a/source3/modules/vfs_default.c b/source3/modules/vfs_default.c index ec6e6e912a..b96a2d201c 100644 --- a/source3/modules/vfs_default.c +++ b/source3/modules/vfs_default.c @@ -1156,9 +1156,9 @@ ssize_t vfswrap_llistxattr(struct vfs_handle_struct *handle, const char *path, c return sys_llistxattr(path, list, size); } -ssize_t vfswrap_flistxattr(struct vfs_handle_struct *handle, struct files_struct *fsp,int fd, char *list, size_t size) +ssize_t vfswrap_flistxattr(struct vfs_handle_struct *handle, struct files_struct *fsp, char *list, size_t size) { - return sys_flistxattr(fd, list, size); + return sys_flistxattr(fsp->fh->fd, list, size); } static int vfswrap_removexattr(struct vfs_handle_struct *handle, const char *path, const char *name) diff --git a/source3/modules/vfs_full_audit.c b/source3/modules/vfs_full_audit.c index 82e212ed0a..ecf136347c 100644 --- a/source3/modules/vfs_full_audit.c +++ b/source3/modules/vfs_full_audit.c @@ -277,7 +277,7 @@ static ssize_t smb_full_audit_listxattr(struct vfs_handle_struct *handle, static ssize_t smb_full_audit_llistxattr(struct vfs_handle_struct *handle, const char *path, char *list, size_t size); static ssize_t smb_full_audit_flistxattr(struct vfs_handle_struct *handle, - struct files_struct *fsp, int fd, char *list, + struct files_struct *fsp, char *list, size_t size); static int smb_full_audit_removexattr(struct vfs_handle_struct *handle, const char *path, @@ -1994,12 +1994,12 @@ static ssize_t smb_full_audit_llistxattr(struct vfs_handle_struct *handle, } static ssize_t smb_full_audit_flistxattr(struct vfs_handle_struct *handle, - struct files_struct *fsp, int fd, char *list, + struct files_struct *fsp, char *list, size_t size) { ssize_t result; - result = SMB_VFS_NEXT_FLISTXATTR(handle, fsp, fd, list, size); + result = SMB_VFS_NEXT_FLISTXATTR(handle, fsp, list, size); do_log(SMB_VFS_OP_FLISTXATTR, (result >= 0), handle, "%s", fsp->fsp_name); diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c index 42914298fa..2958985b02 100644 --- a/source3/smbd/trans2.c +++ b/source3/smbd/trans2.c @@ -187,7 +187,7 @@ static struct ea_list *get_ea_list_from_file(TALLOC_CTX *mem_ctx, connection_str } if (fsp && fsp->fh->fd != -1) { - sizeret = SMB_VFS_FLISTXATTR(fsp, fsp->fh->fd, ea_namelist, ea_namelist_size); + sizeret = SMB_VFS_FLISTXATTR(fsp, ea_namelist, ea_namelist_size); } else { sizeret = SMB_VFS_LISTXATTR(conn, fname, ea_namelist, ea_namelist_size); } |