You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
DnsQueryEx which does an asynchronous procedure call so it eliminates the need for thread pool
DnsQueryEx is only available on Windows 8 so would have to be feature-tested at runtime. It would also be good to double-check if it's really asynchronous and not just using the Windows thread pool.
Replacing GetAddrInfoW with DnsQuery_W doesn't seem compelling on its own but DnsQueryEx might be a good reason to switch. It should be 100% backwards compatible though.
DnsQueryEx supports cancellation, already asynchronous through APC and it also returns TTL value (I'm not sure if GetAddrInfoW reports TTL too, though). Other than this variant, they're pretty similar I think.
I've also tried GetAddrInfoExW, though it takes OVERLAPPED, it returns nonzero when the aforementioned argument is given.
I actually want to take part in implementing it, I thought this might be a good first issue as well.
The GetAddrInfoExW looks better, since it is in the existing ws2_32 library and seems to support passing an Event object via OVERLAPPED (which can be used with IOCP directly)
Currently
GetAddrInfoW
is used for DNS queries on Windows. WinDNS functions seems superior to getaddrinfo and it's counterparts. We have:and
DnsQueryEx
which does an asynchronous procedure call so it eliminates the need for thread pool (also supports wide characters).The text was updated successfully, but these errors were encountered: