summaryrefslogtreecommitdiff
path: root/source3/msrpc
diff options
context:
space:
mode:
Diffstat (limited to 'source3/msrpc')
-rw-r--r--source3/msrpc/msrpcd.c2
-rw-r--r--source3/msrpc/msrpcd_process.c14
2 files changed, 15 insertions, 1 deletions
diff --git a/source3/msrpc/msrpcd.c b/source3/msrpc/msrpcd.c
index 942d6f1258..d6ae3ca642 100644
--- a/source3/msrpc/msrpcd.c
+++ b/source3/msrpc/msrpcd.c
@@ -558,7 +558,7 @@ int msrpc_main(int argc,char *argv[])
fstrcpy(static_pipe.name, pipe_name);
if (msrpcd_init(ClientMSRPC, &static_pipe))
{
- reload_services(False);
+ reload_services(True);
msrpcd_process(ClientMSRPC, &static_pipe);
}
if (ClientMSRPC != -1)
diff --git a/source3/msrpc/msrpcd_process.c b/source3/msrpc/msrpcd_process.c
index 240087be14..35a28d105a 100644
--- a/source3/msrpc/msrpcd_process.c
+++ b/source3/msrpc/msrpcd_process.c
@@ -355,6 +355,7 @@ BOOL msrpcd_init(int c, pipes_struct *p)
{
struct user_creds usr;
gid_t *groups = NULL;
+ char *user;
if (!get_user_creds(c, &usr))
{
@@ -405,6 +406,19 @@ BOOL msrpcd_init(int c, pipes_struct *p)
ZERO_STRUCTP(p->l);
+ user = usr.uxc.user_name;
+ if (!strequal(user,lp_guestaccount(-1)) &&
+ lp_servicenumber(user) < 0)
+ {
+ int homes = lp_servicenumber(HOMES_NAME);
+ char *home = get_unixhome_dir(user);
+ if (homes >= 0 && home)
+ {
+ pstring home_dir;
+ fstrcpy(home_dir, home);
+ lp_add_home(user,homes,home_dir);
+ }
+ }
return True;
}