diff options
author | Tim Prouty <tprouty@samba.org> | 2009-07-21 09:29:59 -0700 |
---|---|---|
committer | Tim Prouty <tprouty@samba.org> | 2009-07-21 12:04:58 -0700 |
commit | 6b49f28592af5c998642bd5d5f76b77c79a22cd7 (patch) | |
tree | 470fda300240a8fe64328a6c17e540e1244c0ea1 /source3/smbd/open.c | |
parent | 424e7636957f07c044ee24a9bbf650b02291939b (diff) | |
download | samba-6b49f28592af5c998642bd5d5f76b77c79a22cd7.tar.gz samba-6b49f28592af5c998642bd5d5f76b77c79a22cd7.tar.bz2 samba-6b49f28592af5c998642bd5d5f76b77c79a22cd7.zip |
s3: Plumb smb_filename through map_open_params_to_ntcreate
Diffstat (limited to 'source3/smbd/open.c')
-rw-r--r-- | source3/smbd/open.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/source3/smbd/open.c b/source3/smbd/open.c index 7692c7c847..87cab1966b 100644 --- a/source3/smbd/open.c +++ b/source3/smbd/open.c @@ -1199,7 +1199,8 @@ NTSTATUS fcb_or_dos_open(struct smb_request *req, Open a file with a share mode - old openX method - map into NTCreate. ****************************************************************************/ -bool map_open_params_to_ntcreate(const char *fname, int deny_mode, int open_func, +bool map_open_params_to_ntcreate(const struct smb_filename *smb_fname, + int deny_mode, int open_func, uint32 *paccess_mask, uint32 *pshare_mode, uint32 *pcreate_disposition, @@ -1212,7 +1213,8 @@ bool map_open_params_to_ntcreate(const char *fname, int deny_mode, int open_func DEBUG(10,("map_open_params_to_ntcreate: fname = %s, deny_mode = 0x%x, " "open_func = 0x%x\n", - fname, (unsigned int)deny_mode, (unsigned int)open_func )); + smb_fname_str_dbg(smb_fname), (unsigned int)deny_mode, + (unsigned int)open_func )); /* Create the NT compatible access_mask. */ switch (GET_OPENX_MODE(deny_mode)) { @@ -1286,7 +1288,7 @@ bool map_open_params_to_ntcreate(const char *fname, int deny_mode, int open_func case DENY_DOS: create_options |= NTCREATEX_OPTIONS_PRIVATE_DENY_DOS; - if (is_executable(fname)) { + if (is_executable(smb_fname->base_name)) { share_mode = FILE_SHARE_READ|FILE_SHARE_WRITE; } else { if (GET_OPENX_MODE(deny_mode) == DOS_OPEN_RDONLY) { @@ -1311,7 +1313,7 @@ bool map_open_params_to_ntcreate(const char *fname, int deny_mode, int open_func DEBUG(10,("map_open_params_to_ntcreate: file %s, access_mask = 0x%x, " "share_mode = 0x%x, create_disposition = 0x%x, " "create_options = 0x%x\n", - fname, + smb_fname_str_dbg(smb_fname), (unsigned int)access_mask, (unsigned int)share_mode, (unsigned int)create_disposition, |