summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorTim Prouty <tprouty@samba.org>2008-11-22 19:37:24 -0800
committerTim Prouty <tprouty@samba.org>2008-12-03 17:51:23 -0800
commit6f7f4b428a86921e9532c62856873a19202f286d (patch)
treefd23e9d3496fa5d04ece875a6f758759734e79d1 /source3
parent08ce0604757315367f26a2c0869d59dd229c3ffe (diff)
downloadsamba-6f7f4b428a86921e9532c62856873a19202f286d.tar.gz
samba-6f7f4b428a86921e9532c62856873a19202f286d.tar.bz2
samba-6f7f4b428a86921e9532c62856873a19202f286d.zip
s3: Modify direct caller of open_file to call SMB_VFS_CREATE_FILE
Diffstat (limited to 'source3')
-rw-r--r--source3/smbd/open.c23
1 files changed, 19 insertions, 4 deletions
diff --git a/source3/smbd/open.c b/source3/smbd/open.c
index 62d4827bb2..2e34115071 100644
--- a/source3/smbd/open.c
+++ b/source3/smbd/open.c
@@ -2143,10 +2143,25 @@ NTSTATUS open_file_fchmod(struct smb_request *req, connection_struct *conn,
return status;
}
- /* note! we must use a non-zero desired access or we don't get
- a real file descriptor. Oh what a twisted web we weave. */
- status = open_file(fsp, conn, NULL, NULL, NULL, fname, psbuf, O_WRONLY,
- 0, FILE_WRITE_DATA, FILE_WRITE_DATA);
+ status = SMB_VFS_CREATE_FILE(
+ conn, /* conn */
+ NULL, /* req */
+ 0, /* root_dir_fid */
+ fname, /* fname */
+ false, /* is_dos_path */
+ FILE_WRITE_DATA, /* access_mask */
+ (FILE_SHARE_READ | FILE_SHARE_WRITE | /* share_access */
+ FILE_SHARE_DELETE),
+ FILE_OPEN, /* create_disposition*/
+ 0, /* create_options */
+ 0, /* file_attributes */
+ 0, /* oplock_request */
+ 0, /* allocation_size */
+ NULL, /* sd */
+ NULL, /* ea_list */
+ &fsp, /* result */
+ NULL, /* pinfo */
+ psbuf); /* psbuf */
/*
* This is not a user visible file open.