Hello,
I am using ares_gethostbyname with the following:
...
int mask = ARES_OPT_FLAGS|ARES_OPT_SERVERS;
...
opt.flags = ARES_FLAG_NOCHECKRESP;
opt.timeout = 1;
...
ares_init_options(&ch, &opt, mask);
...
ares_gethostbyname(ch, "www.google.com", PF_INET, callback, (char *)ns);
This works fine, and I get a response, but if I tcpdump while this
program runs, I see that it's using TCP instead of UDP. It was my
understanding from the documentation that it would only use TCP if the
record size was too large.
Am I missing a mask option or flag to force UDP?
Thanks!
Josh
Received on 2008-01-20