diff options
Diffstat (limited to 'source4/ntvfs/simple')
-rw-r--r-- | source4/ntvfs/simple/vfs_simple.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/source4/ntvfs/simple/vfs_simple.c b/source4/ntvfs/simple/vfs_simple.c index beffe2b546..ccb8b1b97c 100644 --- a/source4/ntvfs/simple/vfs_simple.c +++ b/source4/ntvfs/simple/vfs_simple.c @@ -39,7 +39,7 @@ #define O_DIRECTORY 0 #endif -#define CHECK_READ_ONLY(req) do { if (lp_readonly(ntvfs->ctx->config.snum)) return NT_STATUS_ACCESS_DENIED; } while (0) +#define CHECK_READ_ONLY(req) do { if (share_bool_option(ntvfs->ctx->config, SHARE_READONLY, True)) return NT_STATUS_ACCESS_DENIED; } while (0) /* connect to a share - used when a tree_connect operation comes @@ -52,13 +52,13 @@ static NTSTATUS svfs_connect(struct ntvfs_module_context *ntvfs, { struct stat st; struct svfs_private *private; - int snum = ntvfs->ctx->config.snum; + struct share_config *scfg = ntvfs->ctx->config; private = talloc(ntvfs, struct svfs_private); NT_STATUS_HAVE_NO_MEMORY(private); private->ntvfs = ntvfs; private->next_search_handle = 0; - private->connectpath = talloc_strdup(private, lp_pathname(snum)); + private->connectpath = talloc_strdup(private, share_string_option(scfg, SHARE_PATH, "")); private->open_files = NULL; private->search = NULL; @@ -319,7 +319,7 @@ static NTSTATUS svfs_open(struct ntvfs_module_context *ntvfs, return ntvfs_map_open(ntvfs, req, io); } - readonly = lp_readonly(ntvfs->ctx->config.snum); + readonly = share_bool_option(ntvfs->ctx->config, SHARE_READONLY, SHARE_READONLY_DEFAULT); if (readonly) { create_flags = 0; rdwr_flags = O_RDONLY; @@ -775,7 +775,7 @@ static NTSTATUS svfs_fsinfo(struct ntvfs_module_context *ntvfs, fs->generic.out.quota_soft = 0; fs->generic.out.quota_hard = 0; fs->generic.out.quota_flags = 0; - fs->generic.out.volume_name = talloc_strdup(req, lp_servicename(ntvfs->ctx->config.snum)); + fs->generic.out.volume_name = talloc_strdup(req, ntvfs->ctx->config->name); fs->generic.out.fs_type = ntvfs->ctx->fs_type; return NT_STATUS_OK; |