--- a/net/dns/public/scoped_res_state.cc.orig +++ b/net/dns/public/scoped_res_state.cc @@ -13,7 +13,7 @@ namespace net { ScopedResState::ScopedResState() { -#if BUILDFLAG(IS_OPENBSD) || BUILDFLAG(IS_FUCHSIA) +#if BUILDFLAG(IS_OPENBSD) || BUILDFLAG(IS_FUCHSIA) || (BUILDFLAG(IS_LINUX) && !defined(__GLIBC__)) // Note: res_ninit in glibc always returns 0 and sets RES_INIT. // res_init behaves the same way. memset(&_res, 0, sizeof(_res)); --- a/net/dns/public/scoped_res_state.cc +++ b/net/dns/public/scoped_res_state.cc @@ -25,7 +25,7 @@ } ScopedResState::~ScopedResState() { -#if !BUILDFLAG(IS_OPENBSD) && !BUILDFLAG(IS_FUCHSIA) +#if !BUILDFLAG(IS_OPENBSD) && !BUILDFLAG(IS_FUCHSIA) && !(BUILDFLAG(IS_LINUX) && !defined(__GLIBC__)) // Prefer res_ndestroy where available. #if BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_FREEBSD) @@ -34,7 +34,7 @@ res_nclose(&res_); #endif // BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_FREEBSD) -#endif // !BUILDFLAG(IS_OPENBSD) && !BUILDFLAG(IS_FUCHSIA) +#endif // !BUILDFLAG(IS_OPENBSD) && !BUILDFLAG(IS_FUCHSIA) && !(BUILDFLAG(IS_LINUX) && !defined(__GLIBC__)) } bool ScopedResState::IsValid() const { --- a/net/dns/host_resolver_manager.cc.orig +++ b/net/dns/host_resolver_manager.cc @@ -3015,7 +3015,7 @@ if (system_dns_config_notifier_) system_dns_config_notifier_->AddObserver(this); #if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_APPLE) && !BUILDFLAG(IS_OPENBSD) && \ - !BUILDFLAG(IS_ANDROID) + !BUILDFLAG(IS_ANDROID) && !(BUILDFLAG(IS_LINUX) && !defined(__GLIBC__)) EnsureDnsReloaderInit(); #endif --- a/net/dns/dns_reloader.cc.orig +++ b/net/dns/dns_reloader.cc @@ -7,7 +7,8 @@ #include "build/build_config.h" #if BUILDFLAG(IS_POSIX) && !BUILDFLAG(IS_APPLE) && !BUILDFLAG(IS_OPENBSD) && \ - !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_FUCHSIA) + !BUILDFLAG(IS_ANDROID) && !BUILDFLAG(IS_FUCHSIA) && \ + !(BUILDFLAG(IS_LINUX) && !defined(__GLIBC__)) #include --- a/net/dns/host_resolver_proc.cc.orig +++ b/net/dns/host_resolver_proc.cc @@ -177,7 +177,8 @@ base::BlockingType::WILL_BLOCK); #if BUILDFLAG(IS_POSIX) && \ - !(BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_OPENBSD) || BUILDFLAG(IS_ANDROID)) + !(BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_OPENBSD) || BUILDFLAG(IS_ANDROID) || \ + (BUILDFLAG(IS_LINUX) && !defined(__GLIBC__))) DnsReloaderMaybeReload(); #endif absl::optional ai;