diff options
author | Abhidnya P Chirmule <achirmul@in.ibm.com> | 2009-10-06 17:14:56 +0200 |
---|---|---|
committer | Volker Lendecke <vl@samba.org> | 2009-10-06 18:52:06 +0200 |
commit | ac774c49691b08fa90121d5bd008618cfd4405e7 (patch) | |
tree | 0072e321869ed910c619d65ff57c0b59ee9956d6 /source3/include | |
parent | c344bf0184be484fff8bb5ed93b5c2ca6de58611 (diff) | |
download | samba-ac774c49691b08fa90121d5bd008618cfd4405e7.tar.gz samba-ac774c49691b08fa90121d5bd008618cfd4405e7.tar.bz2 samba-ac774c49691b08fa90121d5bd008618cfd4405e7.zip |
s3: Add access_mask to the flock VFS call
Diffstat (limited to 'source3/include')
-rw-r--r-- | source3/include/proto.h | 2 | ||||
-rw-r--r-- | source3/include/vfs.h | 6 | ||||
-rw-r--r-- | source3/include/vfs_macros.h | 8 |
3 files changed, 9 insertions, 7 deletions
diff --git a/source3/include/proto.h b/source3/include/proto.h index c8e4fe1916..d31483a02e 100644 --- a/source3/include/proto.h +++ b/source3/include/proto.h @@ -937,7 +937,7 @@ SMB_OFF_T sys_ftell(FILE *fp); int sys_creat(const char *path, mode_t mode); int sys_open(const char *path, int oflag, mode_t mode); FILE *sys_fopen(const char *path, const char *type); -void kernel_flock(int fd, uint32 share_mode); +void kernel_flock(int fd, uint32 share_mode, uint32 access_mask); SMB_STRUCT_DIR *sys_opendir(const char *name); SMB_STRUCT_DIRENT *sys_readdir(SMB_STRUCT_DIR *dirp); void sys_seekdir(SMB_STRUCT_DIR *dirp, long offset); diff --git a/source3/include/vfs.h b/source3/include/vfs.h index ed49d1fd28..f9c1f0a54f 100644 --- a/source3/include/vfs.h +++ b/source3/include/vfs.h @@ -247,7 +247,8 @@ struct vfs_fn_pointers { struct smb_file_time *ft); int (*ftruncate)(struct vfs_handle_struct *handle, struct files_struct *fsp, SMB_OFF_T offset); bool (*lock)(struct vfs_handle_struct *handle, struct files_struct *fsp, int op, SMB_OFF_T offset, SMB_OFF_T count, int type); - int (*kernel_flock)(struct vfs_handle_struct *handle, struct files_struct *fsp, uint32 share_mode); + int (*kernel_flock)(struct vfs_handle_struct *handle, struct files_struct *fsp, + uint32 share_mode, uint32_t access_mask); int (*linux_setlease)(struct vfs_handle_struct *handle, struct files_struct *fsp, int leasetype); bool (*getlock)(struct vfs_handle_struct *handle, struct files_struct *fsp, SMB_OFF_T *poffset, SMB_OFF_T *pcount, int *ptype, pid_t *ppid); int (*symlink)(struct vfs_handle_struct *handle, const char *oldpath, const char *newpath); @@ -598,7 +599,8 @@ bool smb_vfs_call_lock(struct vfs_handle_struct *handle, struct files_struct *fsp, int op, SMB_OFF_T offset, SMB_OFF_T count, int type); int smb_vfs_call_kernel_flock(struct vfs_handle_struct *handle, - struct files_struct *fsp, uint32 share_mode); + struct files_struct *fsp, uint32 share_mode, + uint32_t access_mask); int smb_vfs_call_linux_setlease(struct vfs_handle_struct *handle, struct files_struct *fsp, int leasetype); bool smb_vfs_call_getlock(struct vfs_handle_struct *handle, diff --git a/source3/include/vfs_macros.h b/source3/include/vfs_macros.h index 8ca7f373bf..7206bf41bb 100644 --- a/source3/include/vfs_macros.h +++ b/source3/include/vfs_macros.h @@ -250,10 +250,10 @@ #define SMB_VFS_NEXT_LOCK(handle, fsp, op, offset, count, type) \ smb_vfs_call_lock((handle)->next, (fsp), (op), (offset), (count), (type)) -#define SMB_VFS_KERNEL_FLOCK(fsp, share_mode) \ - smb_vfs_call_kernel_flock((fsp)->conn->vfs_handles, (fsp), (share_mode)) -#define SMB_VFS_NEXT_KERNEL_FLOCK(handle, fsp, share_mode) \ - smb_vfs_call_kernel_flock((handle)->next, (fsp), (share_mode)) +#define SMB_VFS_KERNEL_FLOCK(fsp, share_mode, access_mask) \ + smb_vfs_call_kernel_flock((fsp)->conn->vfs_handles, (fsp), (share_mode), (access_mask)) +#define SMB_VFS_NEXT_KERNEL_FLOCK(handle, fsp, share_mode, access_mask) \ + smb_vfs_call_kernel_flock((handle)->next, (fsp), (share_mode), (access_mask)) #define SMB_VFS_LINUX_SETLEASE(fsp, leasetype) \ smb_vfs_call_linux_setlease((fsp)->conn->vfs_handles, (fsp), (leasetype)) |