diff options
author | Andrew Bartlett <abartlet@samba.org> | 2008-03-27 20:32:02 +1100 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2008-03-27 20:32:02 +1100 |
commit | 4fc27c9969960dfef73ad80438d274e0f45e119e (patch) | |
tree | ea558da1f71c52f8c1daa13de7eff7ecb72d322e /source4/param | |
parent | 83ea6d5f55dcb18da48cee880624ed4530f9c05f (diff) | |
download | samba-4fc27c9969960dfef73ad80438d274e0f45e119e.tar.gz samba-4fc27c9969960dfef73ad80438d274e0f45e119e.tar.bz2 samba-4fc27c9969960dfef73ad80438d274e0f45e119e.zip |
Make oplocks a per-share option.
This even goes via the share options system (a very odd layer of indirection).
Andrew Bartlett
(This used to be commit f2c65f9907760b8852b70c53637388f08751ba88)
Diffstat (limited to 'source4/param')
-rw-r--r-- | source4/param/loadparm.c | 6 | ||||
-rw-r--r-- | source4/param/share.h | 2 |
2 files changed, 7 insertions, 1 deletions
diff --git a/source4/param/loadparm.c b/source4/param/loadparm.c index a1d29b0771..9e0a239abe 100644 --- a/source4/param/loadparm.c +++ b/source4/param/loadparm.c @@ -210,6 +210,7 @@ struct loadparm_service int bMap_hidden; int bMap_archive; int bStrictLocking; + int bOplocks; int iCreate_mask; int iCreate_force_mode; int iDir_mask; @@ -715,6 +716,7 @@ _PUBLIC_ FN_LOCAL_BOOL(lp_print_ok, bPrint_ok) _PUBLIC_ FN_LOCAL_BOOL(lp_map_hidden, bMap_hidden) _PUBLIC_ FN_LOCAL_BOOL(lp_map_archive, bMap_archive) _PUBLIC_ FN_LOCAL_BOOL(lp_strict_locking, bStrictLocking) +_PUBLIC_ FN_LOCAL_BOOL(lp_oplocks, bOplocks) _PUBLIC_ FN_LOCAL_BOOL(lp_strict_sync, bStrictSync) _PUBLIC_ FN_LOCAL_BOOL(lp_ci_filesystem, bCIFileSystem) _PUBLIC_ FN_LOCAL_BOOL(lp_map_system, bMap_system) @@ -2292,7 +2294,7 @@ struct loadparm_context *loadparm_init(TALLOC_CTX *mem_ctx) lp_do_global_parameter(lp_ctx, "max connections", "-1"); lp_do_global_parameter(lp_ctx, "dcerpc endpoint servers", "epmapper srvsvc wkssvc rpcecho samr netlogon lsarpc spoolss drsuapi winreg dssetup unixinfo"); - lp_do_global_parameter(lp_ctx, "server services", "smb rpc nbt wrepl ldap cldap web kdc drepl winbind"); + lp_do_global_parameter(lp_ctx, "server services", "smb rpc nbt wrepl ldap cldap kdc drepl winbind"); lp_do_global_parameter(lp_ctx, "ntptr providor", "simple_ldb"); lp_do_global_parameter(lp_ctx, "auth methods:domain controller", "anonymous sam_ignoredomain"); lp_do_global_parameter(lp_ctx, "auth methods:member server", "anonymous sam winbind"); @@ -2406,6 +2408,8 @@ struct loadparm_context *loadparm_init(TALLOC_CTX *mem_ctx) lp_do_global_parameter(lp_ctx, "prefork children:smb", "4"); + lp_do_global_parameter(lp_ctx, "oplocks", "true"); + for (i = 0; parm_table[i].label; i++) { if (!(lp_ctx->flags[i] & FLAG_CMDLINE)) { lp_ctx->flags[i] |= FLAG_DEFAULT; diff --git a/source4/param/share.h b/source4/param/share.h index 51f45781c1..9f9cbdce5b 100644 --- a/source4/param/share.h +++ b/source4/param/share.h @@ -90,6 +90,7 @@ struct loadparm_context; #define SHARE_MAP_ARCHIVE "map-archive" #define SHARE_STRICT_LOCKING "strict-locking" +#define SHARE_OPLOCKS "oplocks" #define SHARE_STRICT_SYNC "strict-sync" #define SHARE_MSDFS_ROOT "msdfs-root" #define SHARE_CI_FILESYSTEM "ci-filesystem" @@ -125,6 +126,7 @@ struct loadparm_context; #define SHARE_MAP_ARCHIVE_DEFAULT true #define SHARE_STRICT_LOCKING_DEFAULT true +#define SHARE_OPLOCKS_DEFAULT true #define SHARE_STRICT_SYNC_DEFAULT false #define SHARE_MSDFS_ROOT_DEFAULT false #define SHARE_CI_FILESYSTEM_DEFAULT false |