From ee61568be6bcb217d106c08ec915775c8476ed56 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Tue, 14 Sep 2010 17:36:23 +1000 Subject: s4-winbind: use finddcs_cldap() in winbind Pair-Programmed-With: Andrew Bartlett --- source4/winbind/wb_init_domain.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) (limited to 'source4/winbind/wb_init_domain.c') diff --git a/source4/winbind/wb_init_domain.c b/source4/winbind/wb_init_domain.c index f07d17a64e..50a6af05fd 100644 --- a/source4/winbind/wb_init_domain.c +++ b/source4/winbind/wb_init_domain.c @@ -128,16 +128,8 @@ struct composite_context *wb_init_domain_send(TALLOC_CTX *mem_ctx, state->domain->info = talloc_reference(state->domain, dom_info); if (state->domain->info == NULL) goto failed; - /* Caller should check, but to be safe: */ - if (dom_info->num_dcs < 1) { - goto failed; - } - - /* For now, we just pick the first. The next step will be to - * walk the entire list. Also need to fix finddcs() to return - * the entire list */ - state->domain->dc_name = dom_info->dcs[0].name; - state->domain->dc_address = dom_info->dcs[0].address; + state->domain->dc_name = dom_info->dc->name; + state->domain->dc_address = dom_info->dc->address; state->domain->libnet_ctx = libnet_context_init(service->task->event_ctx, service->task->lp_ctx); -- cgit