Make oplocks a per-share option.
[samba.git] / source / ntvfs / common / opendb_tdb.c
index be78e0995810497e8fad6da7e75caaff1760d6b8..40a1d27f3016966692eaf1c7663e7328ac013b98 100644 (file)
@@ -101,8 +101,7 @@ static struct odb_context *odb_tdb_init(TALLOC_CTX *mem_ctx,
 
        odb->ntvfs_ctx = ntvfs_ctx;
 
-       /* leave oplocks disabled by default until the code is working */
-       odb->oplocks = lp_parm_bool(ntvfs_ctx->lp_ctx, NULL, "opendb", "oplocks", false);
+       odb->oplocks = share_bool_option(ntvfs_ctx->ctx->config, SHARE_OPLOCKS, SHARE_OPLOCKS_DEFAULT);
 
        odb->lease_ctx = sys_lease_context_create(ntvfs_ctx->config, odb,
                                                  ntvfs_ctx->event_ctx,