summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2002-03-09 19:37:57 +0000
committerAndrew Tridgell <tridge@samba.org>2002-03-09 19:37:57 +0000
commitb9becd752cce8b23a6b5082f013a6c6e0d4698e9 (patch)
tree459cfcfc0ebbee92684a6c4f4fd9a621a0314029 /source3
parente1aed4f49c158522ab4a22767db035f3c83c0b5f (diff)
downloadsamba-b9becd752cce8b23a6b5082f013a6c6e0d4698e9.tar.gz
samba-b9becd752cce8b23a6b5082f013a6c6e0d4698e9.tar.bz2
samba-b9becd752cce8b23a6b5082f013a6c6e0d4698e9.zip
prevent a segv when a trusted domain is unavailable at startup
(This used to be commit d5b5d3f8400a80c943809db9578a2d7317aa6d2d)
Diffstat (limited to 'source3')
-rw-r--r--source3/nsswitch/winbindd_util.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/source3/nsswitch/winbindd_util.c b/source3/nsswitch/winbindd_util.c
index e274c78220..06804b3b43 100644
--- a/source3/nsswitch/winbindd_util.c
+++ b/source3/nsswitch/winbindd_util.c
@@ -159,9 +159,8 @@ BOOL init_domain_list(void)
int i;
for(i = 0; i < num_domains; i++) {
domain = add_trusted_domain(names[i], &cache_methods);
- if (domain) {
- sid_copy(&domain->sid, &dom_sids[i]);
- }
+ if (!domain) continue;
+ sid_copy(&domain->sid, &dom_sids[i]);
DEBUG(1,("Added domain %s (%s)\n",
domain->name,
sid_string_static(&domain->sid)));