curl / Mailing Lists / curl-library / Single Mail
Buy commercial curl support. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder Daniel himself.

Re: HTTPS RR side of things

From: Daniel Stenberg via curl-library <curl-library_at_lists.haxx.se>
Date: Fri, 21 Feb 2025 23:02:24 +0100 (CET)

On Fri, 21 Feb 2025, Niall O'Reilly wrote:

> I wonder whether you've considered res_nquery(), the non-blocking successor
> to res_query()? I see it in glibc; I haven't looked in Apple or BSD land.
> Building without having to install an extra package (such as c-ares) might
> be attractive. Perhaps there are disadvantages?

Is it really non-blocking? The docs I've read does not seem to say so.

There are (other) significant drawbacks with using this API: primarily that it
is limited to just a small subset of platforms. It does not even exist on
Windows or macOS and it's broken on Android etc. We would have to use a wide
range of different native APIs to cover just the most commonly used OSes - way
more work than just making sure that a solid DNS library like c-ares is used
instead.

Mozilla took the "native API" route, and Valentin Gosu's talk from this year's
FOSDEM provides reasons enough for me to avoid selecting this approach:

"getaddrinfo sucks, everything else is much worse"

The video recording is here:

https://video.fosdem.org/2025/h2213/fosdem-2025-4229-getaddrinfo-sucks-everything-else-is-much-worse.mp4

-- 
  / daniel.haxx.se || https://rock-solid.curl.dev
-- 
Unsubscribe: https://lists.haxx.se/mailman/listinfo/curl-library
Etiquette:   https://curl.se/mail/etiquette.html
Received on 2025-02-21