summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2011-05-08 10:29:27 +0200
committerAndrew Bartlett <abartlet@samba.org>2011-05-08 19:00:29 +0200
commitaae9353ecf56323b63da66aa84d8a0a4f219d94d (patch)
treef290f32f705a98002d0bb54e359a8f91f1bc3834 /source4
parenteae061293bad97e6e70526b4e755ca69c02d0ae9 (diff)
downloadsamba-aae9353ecf56323b63da66aa84d8a0a4f219d94d.tar.gz
samba-aae9353ecf56323b63da66aa84d8a0a4f219d94d.tar.bz2
samba-aae9353ecf56323b63da66aa84d8a0a4f219d94d.zip
ncalrpc: Force ncalrpc dir to be mode 755 in all users
This allows this directory to be shared between Samba3 and Samba4 in a Franky-style setup easily. Andrew Bartlett
Diffstat (limited to 'source4')
-rw-r--r--source4/smbd/service_named_pipe.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/source4/smbd/service_named_pipe.c b/source4/smbd/service_named_pipe.c
index fc221c1c7e..bcfd5effe4 100644
--- a/source4/smbd/service_named_pipe.c
+++ b/source4/smbd/service_named_pipe.c
@@ -200,6 +200,13 @@ NTSTATUS tstream_setup_named_pipe(TALLOC_CTX *mem_ctx,
goto fail;
}
+ if (!directory_create_or_exist(lpcfg_ncalrpc_dir(lp_ctx), geteuid(), 0755)) {
+ status = map_nt_error_from_unix(errno);
+ DEBUG(0,(__location__ ": Failed to create ncalrpc pipe directory '%s' - %s\n",
+ lpcfg_ncalrpc_dir(lp_ctx), nt_errstr(status)));
+ goto fail;
+ }
+
dirname = talloc_asprintf(pipe_sock, "%s/np", lpcfg_ncalrpc_dir(lp_ctx));
if (dirname == NULL) {
goto fail;