summaryrefslogtreecommitdiffstats
path: root/source/smbd
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2002-01-27 12:12:22 +0000
committerAndrew Bartlett <abartlet@samba.org>2002-01-27 12:12:22 +0000
commitf1d8d509766e9169d39332559162cfec249bfc70 (patch)
tree8ab3e7e1fff254659c5e075da15b2a06b6b0c2dd /source/smbd
parent8cac618174365825e8b1824f70cb42afbce5e500 (diff)
downloadsamba-f1d8d509766e9169d39332559162cfec249bfc70.tar.gz
samba-f1d8d509766e9169d39332559162cfec249bfc70.tar.xz
samba-f1d8d509766e9169d39332559162cfec249bfc70.zip
Some more 'winbind default domain' support patches from Alexander Bokovoy
<a.bokovoy@sam-solutions.net>. This patch is designed to remove the 'special cases' required for this support. In particular this now kills off winbind_initgroups, as it appears no longer to be required. Andrew Bartlett
Diffstat (limited to 'source/smbd')
-rw-r--r--source/smbd/sec_ctx.c2
-rw-r--r--source/smbd/service.c8
2 files changed, 3 insertions, 7 deletions
diff --git a/source/smbd/sec_ctx.c b/source/smbd/sec_ctx.c
index b774947d607..5802c97f3d1 100644
--- a/source/smbd/sec_ctx.c
+++ b/source/smbd/sec_ctx.c
@@ -185,7 +185,7 @@ BOOL initialise_groups(char *user, uid_t uid, gid_t gid)
/* Call initgroups() to get user groups */
- if (winbind_initgroups(user,gid) == -1) {
+ if (initgroups(user,gid) == -1) {
DEBUG(0,("Unable to initgroups. Error was %s\n", strerror(errno) ));
if (getuid() == 0) {
if (gid < 0 || gid > 32767 || uid < 0 || uid > 32767) {
diff --git a/source/smbd/service.c b/source/smbd/service.c
index ac2e2ee548f..a9b9a9d4d94 100644
--- a/source/smbd/service.c
+++ b/source/smbd/service.c
@@ -84,7 +84,7 @@ int add_home_service(const char *service, const char *homedir)
int iHomeService;
int iService;
fstring new_service;
- char *usr_p = NULL;
+ fstring domain;
if (!service || !homedir)
return -1;
@@ -99,11 +99,7 @@ int add_home_service(const char *service, const char *homedir)
* include any macros.
*/
- fstrcpy(new_service, service);
-
- if ((usr_p = strchr_m(service,*lp_winbind_separator())) != NULL)
- fstrcpy(new_service, usr_p+1);
-
+ split_domain_and_name(service, domain, new_service);
lp_add_home(new_service, iHomeService, homedir);
iService = lp_servicenumber(new_service);