From b76e065991ec01299225d9da90a627ebe6c1ac97 Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Tue, 4 Oct 2016 11:52:10 +0200 Subject: resolv: Deprecate the "inet6" option and RES_USE_INET6 [BZ #19582] --- nscd/aicache.c | 5 +++-- nscd/nscd_gethst_r.c | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) (limited to 'nscd') diff --git a/nscd/aicache.c b/nscd/aicache.c index 32c8f57..f955be7 100644 --- a/nscd/aicache.c +++ b/nscd/aicache.c @@ -25,6 +25,7 @@ #include #include #include +#include #include #include "dbg_log.h" @@ -110,7 +111,7 @@ addhstaiX (struct database_dyn *db, int fd, request_header *req, IPv6 addresses. Currently this is decided by setting the RES_USE_INET6 bit in _res.options. */ int old_res_options = _res.options; - _res.options &= ~RES_USE_INET6; + _res.options &= ~DEPRECATED_RES_USE_INET6; size_t tmpbuf6len = 1024; char *tmpbuf6 = alloca (tmpbuf6len); @@ -535,7 +536,7 @@ next_nip: } out: - _res.options |= old_res_options & RES_USE_INET6; + _res.options |= old_res_options & DEPRECATED_RES_USE_INET6; if (dataset != NULL && !alloca_used) { diff --git a/nscd/nscd_gethst_r.c b/nscd/nscd_gethst_r.c index 7448add..820a2fe 100644 --- a/nscd/nscd_gethst_r.c +++ b/nscd/nscd_gethst_r.c @@ -17,7 +17,7 @@ . */ #include -#include +#include #include #include #include @@ -42,7 +42,7 @@ __nscd_gethostbyname_r (const char *name, struct hostent *resultbuf, { request_type reqtype; - reqtype = (_res.options & RES_USE_INET6) ? GETHOSTBYNAMEv6 : GETHOSTBYNAME; + reqtype = res_use_inet6 () ? GETHOSTBYNAMEv6 : GETHOSTBYNAME; return nscd_gethst_r (name, strlen (name) + 1, reqtype, resultbuf, buffer, buflen, result, h_errnop); -- cgit v1.1