summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/libsmb/dsgetdcname.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/libsmb/dsgetdcname.c b/source3/libsmb/dsgetdcname.c
index 874a7749b7..5af65c5dca 100644
--- a/source3/libsmb/dsgetdcname.c
+++ b/source3/libsmb/dsgetdcname.c
@@ -524,8 +524,8 @@ static NTSTATUS discover_dc_dns(TALLOC_CTX *mem_ctx,
struct ip_service_name *r = &dclist[count];
- r->port = dcs[i].port;
- r->hostname = dcs[i].hostname;
+ r->port = dcs[count].port;
+ r->hostname = dcs[count].hostname;
if (!(flags & DS_IP_REQUIRED)) {
count++;