summaryrefslogtreecommitdiff
path: root/ares_process.c
diff options
context:
space:
mode:
authorDavid Stuart <dstuart@counterpath.com>2011-05-17 11:53:13 +0200
committerDaniel Stenberg <daniel@haxx.se>2011-05-17 11:53:13 +0200
commit6518b56a5e2bc9e39d720f17fa7dd322a28dc33c (patch)
tree3a7bed56f287de887aaa110391f7116f9f87499f /ares_process.c
parentd60f07d09461b05e6b82a6f4a853963f8102c39a (diff)
downloadc-ares-6518b56a5e2bc9e39d720f17fa7dd322a28dc33c.tar.gz
c-ares-6518b56a5e2bc9e39d720f17fa7dd322a28dc33c.tar.bz2
c-ares-6518b56a5e2bc9e39d720f17fa7dd322a28dc33c.zip
IPv6-on-windows: find DNS servers correctly
Diffstat (limited to 'ares_process.c')
-rw-r--r--ares_process.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ares_process.c b/ares_process.c
index a4bf1d2..f5e7d25 100644
--- a/ares_process.c
+++ b/ares_process.c
@@ -684,7 +684,7 @@ static void next_server(ares_channel channel, struct query *query,
* servers to try. In total, we need to do channel->nservers * channel->tries
* attempts. Use query->try to remember how many times we already attempted
* this query. Use modular arithmetic to find the next server to try. */
- while (++(query->try) < (channel->nservers * channel->tries))
+ while (++(query->try_count) < (channel->nservers * channel->tries))
{
struct server_state *server;
@@ -789,7 +789,7 @@ void ares__send_query(ares_channel channel, struct query *query,
return;
}
}
- timeplus = channel->timeout << (query->try / channel->nservers);
+ timeplus = channel->timeout << (query->try_count / channel->nservers);
timeplus = (timeplus * (9 + (rand () & 7))) / 16;
query->timeout = *now;
ares__timeadd(&query->timeout,