From 10ba66164da3cbc9db0e39d3b8c6fbc9f93c64b1 Mon Sep 17 00:00:00 2001 From: Gerald Carter Date: Fri, 1 Aug 2003 13:28:13 +0000 Subject: fix cut-n-paste error found by abartlet (This used to be commit 042492b862c4f2389086275dd8a0e044d7432537) --- source3/nsswitch/winbindd_util.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) (limited to 'source3/nsswitch') diff --git a/source3/nsswitch/winbindd_util.c b/source3/nsswitch/winbindd_util.c index 0de30dbca8..a810e503a0 100644 --- a/source3/nsswitch/winbindd_util.c +++ b/source3/nsswitch/winbindd_util.c @@ -197,20 +197,22 @@ void rescan_trusted_domains(BOOL force) if ( sid_equal(&dom_sids[i], &null_sid) ) { - new_domain = find_domain_from_name(names[i]); + new_domain = find_domain_from_name(names[i]); - /* this should never happen */ - if ( !domain) { - DEBUG(0,("rescan_trust_domains: can't find the domain I just added! [%s]\n", + /* this should never happen */ + if ( !new_domain ) { + DEBUG(0,("rescan_trust_domains: can't find the domain I just added! [%s]\n", names[i])); break; - } + } - result = domain->methods->domain_sid( new_domain, &new_domain->sid ); + /* call the cache method; which will operate on the winbindd_domain \ + passed in and choose either rpc or ads as appropriate */ + + result = domain->methods->domain_sid( new_domain, &new_domain->sid ); - if ( NT_STATUS_IS_OK(result) ) + if ( NT_STATUS_IS_OK(result) ) sid_copy( &dom_sids[i], &domain->sid ); - } /* store trusted domain in the cache */ -- cgit