summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2010-11-08 13:38:13 -0800
committerJeremy Allison <jra@samba.org>2010-11-08 13:38:13 -0800
commit42f9ae875659e9e698a2875cf313c0d2173f94b2 (patch)
tree7fbc4e1e474f497d76ad1423ec9b1e8d4e8e2ae5 /source3
parent842a8e43129d821ebf08cdf4fcba54d3789de756 (diff)
downloadsamba-42f9ae875659e9e698a2875cf313c0d2173f94b2.tar.gz
samba-42f9ae875659e9e698a2875cf313c0d2173f94b2.tar.bz2
samba-42f9ae875659e9e698a2875cf313c0d2173f94b2.zip
First part of fix for bug #7777 - When requesting lookups for BUILTIN sids, winbindd allocates new uids/gids in error.
Ensure idmap_init_passdb_domain() correctly initialized the default domain first. Jeremy.
Diffstat (limited to 'source3')
-rw-r--r--source3/winbindd/idmap.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/source3/winbindd/idmap.c b/source3/winbindd/idmap.c
index 102f4ebb7f..feaf297a7b 100644
--- a/source3/winbindd/idmap.c
+++ b/source3/winbindd/idmap.c
@@ -448,6 +448,16 @@ static struct idmap_domain *idmap_init_passdb_domain(TALLOC_CTX *mem_ctx)
{
idmap_init();
+ /*
+ * Always init the default domain, we can't go without one
+ */
+ if (default_idmap_domain == NULL) {
+ default_idmap_domain = idmap_init_default_domain(NULL);
+ }
+ if (default_idmap_domain == NULL) {
+ return NULL;
+ }
+
if (passdb_idmap_domain != NULL) {
return passdb_idmap_domain;
}