summaryrefslogtreecommitdiff
path: root/source4/ntvfs/ntvfs_generic.c
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2010-03-05 14:57:50 +1100
committerAndrew Tridgell <tridge@samba.org>2010-03-05 16:12:05 +1100
commit80a37beb53519fdbb907a01f29ef150bafdd74e7 (patch)
tree62612e7f4f2de50e537f88f4ded9227f31d875cb /source4/ntvfs/ntvfs_generic.c
parentf01f124969b3e75accfc82fb85487fdab2046e82 (diff)
downloadsamba-80a37beb53519fdbb907a01f29ef150bafdd74e7.tar.gz
samba-80a37beb53519fdbb907a01f29ef150bafdd74e7.tar.bz2
samba-80a37beb53519fdbb907a01f29ef150bafdd74e7.zip
s4-pvfs: move the private ntcreatex flags to private_flags
Re-using two of the create_options bits was bound to eventually cause problems, and indeed, Windows7 now uses one of those bits when opening text files. Fixes bug 7189
Diffstat (limited to 'source4/ntvfs/ntvfs_generic.c')
-rw-r--r--source4/ntvfs/ntvfs_generic.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source4/ntvfs/ntvfs_generic.c b/source4/ntvfs/ntvfs_generic.c
index 547d038738..8e1eb0bc66 100644
--- a/source4/ntvfs/ntvfs_generic.c
+++ b/source4/ntvfs/ntvfs_generic.c
@@ -284,6 +284,7 @@ static NTSTATUS map_openx_open(uint16_t flags, uint16_t open_mode,
union smb_open *io2)
{
io2->generic.in.create_options = NTCREATEX_OPTIONS_NON_DIRECTORY_FILE;
+ io2->generic.in.private_flags = 0;
if (flags & OPENX_FLAGS_REQUEST_OPLOCK) {
io2->generic.in.flags |= NTCREATEX_FLAGS_REQUEST_OPLOCK;
@@ -327,7 +328,7 @@ static NTSTATUS map_openx_open(uint16_t flags, uint16_t open_mode,
break;
case OPENX_MODE_DENY_DOS:
/* DENY_DOS is quite strange - it depends on the filename! */
- io2->generic.in.create_options |=
+ io2->generic.in.private_flags |=
NTCREATEX_OPTIONS_PRIVATE_DENY_DOS;
if (is_exe_filename(fname)) {
io2->generic.in.share_access =
@@ -342,7 +343,7 @@ static NTSTATUS map_openx_open(uint16_t flags, uint16_t open_mode,
}
break;
case OPENX_MODE_DENY_FCB:
- io2->generic.in.create_options |= NTCREATEX_OPTIONS_PRIVATE_DENY_FCB;
+ io2->generic.in.private_flags |= NTCREATEX_OPTIONS_PRIVATE_DENY_FCB;
io2->generic.in.share_access = NTCREATEX_SHARE_ACCESS_NONE;
break;
default:
@@ -528,6 +529,7 @@ NTSTATUS ntvfs_map_open(struct ntvfs_module_context *ntvfs,
io2->generic.in.sec_desc = io->smb2.in.sec_desc;
io2->generic.in.ea_list = &io->smb2.in.eas;
io2->generic.in.query_maximal_access = io->smb2.in.query_maximal_access;
+ io2->generic.in.private_flags = 0;
/* we don't support timewarp yet */
if (io->smb2.in.timewarp != 0) {