From 80a37beb53519fdbb907a01f29ef150bafdd74e7 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Fri, 5 Mar 2010 14:57:50 +1100 Subject: 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 --- source4/libcli/raw/interfaces.h | 3 +++ source4/libcli/raw/smb.h | 12 ++++-------- 2 files changed, 7 insertions(+), 8 deletions(-) (limited to 'source4/libcli/raw') diff --git a/source4/libcli/raw/interfaces.h b/source4/libcli/raw/interfaces.h index f159074783..f6d090539c 100644 --- a/source4/libcli/raw/interfaces.h +++ b/source4/libcli/raw/interfaces.h @@ -1439,6 +1439,9 @@ union smb_open { /* some optional parameters from the SMB2 varient */ bool query_maximal_access; + + /* private flags for internal use only */ + uint8_t private_flags; } in; struct { union smb_handle file; diff --git a/source4/libcli/raw/smb.h b/source4/libcli/raw/smb.h index 349705d2df..7291821fae 100644 --- a/source4/libcli/raw/smb.h +++ b/source4/libcli/raw/smb.h @@ -178,19 +178,15 @@ #define NTCREATEX_OPTIONS_INVALID_PARAM_MASK (NTCREATEX_OPTIONS_OPFILTER | \ NTCREATEX_OPTIONS_SYNC_ALERT | \ NTCREATEX_OPTIONS_ASYNC_ALERT | \ - NTCREATEX_OPTIONS_OPFILTER | \ 0xFF000000) /* - * We reuse some ignored flags for private use. + * private_flags field in ntcreatex * This values have different meaning for some ntvfs backends. - * - * TODO: use values that are ignore for sure... */ -#define NTCREATEX_OPTIONS_PRIVATE_DENY_DOS 0x00010000 -#define NTCREATEX_OPTIONS_PRIVATE_DENY_FCB 0x00020000 -#define NTCREATEX_OPTIONS_PRIVATE_MASK (NTCREATEX_OPTIONS_PRIVATE_DENY_DOS | \ - NTCREATEX_OPTIONS_PRIVATE_DENY_FCB) +#define NTCREATEX_OPTIONS_PRIVATE_DENY_DOS 0x0001 +#define NTCREATEX_OPTIONS_PRIVATE_DENY_FCB 0x0002 + /* ntcreatex impersonation field */ #define NTCREATEX_IMPERSONATION_ANONYMOUS 0 -- cgit