diff options
author | Florian Weimer <fweimer@redhat.com> | 2016-10-04 11:52:10 +0200 |
---|---|---|
committer | Florian Weimer <fweimer@redhat.com> | 2016-12-31 18:55:14 +0100 |
commit | b76e065991ec01299225d9da90a627ebe6c1ac97 (patch) | |
tree | ac94cc82b134096975419ced320f6ed329130756 /nis/nss_nisplus/nisplus-hosts.c | |
parent | 5840c75c2d6a9b980d6789f2ca7d47a9fa067263 (diff) | |
download | glibc-b76e065991ec01299225d9da90a627ebe6c1ac97.tar.gz glibc-b76e065991ec01299225d9da90a627ebe6c1ac97.tar.xz glibc-b76e065991ec01299225d9da90a627ebe6c1ac97.zip |
resolv: Deprecate the "inet6" option and RES_USE_INET6 [BZ #19582]
Diffstat (limited to 'nis/nss_nisplus/nisplus-hosts.c')
-rw-r--r-- | nis/nss_nisplus/nisplus-hosts.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/nis/nss_nisplus/nisplus-hosts.c b/nis/nss_nisplus/nisplus-hosts.c index 2751e5936a..97a03aa21c 100644 --- a/nis/nss_nisplus/nisplus-hosts.c +++ b/nis/nss_nisplus/nisplus-hosts.c @@ -43,6 +43,7 @@ static u_long tablename_len; (NIS_RES_OBJECT (res)[idx].EN_data.en_cols.en_cols_val[col].ec_value.ec_value_len) /* Get implementation for some internal functions. */ +#include <resolv/resolv-internal.h> #include <resolv/mapv4v6addr.h> @@ -321,7 +322,7 @@ internal_nisplus_gethostent_r (struct hostent *host, char *buffer, } } - if (_res.options & RES_USE_INET6) + if (res_use_inet6 ()) parse_res = _nss_nisplus_parse_hostent (result, AF_INET6, host, buffer, buflen, errnop, AI_V4MAPPED); else @@ -488,7 +489,7 @@ _nss_nisplus_gethostbyname2_r (const char *name, int af, struct hostent *host, return internal_gethostbyname2_r (name, af, host, buffer, buflen, errnop, herrnop, - ((_res.options & RES_USE_INET6) ? AI_V4MAPPED : 0)); + (res_use_inet6 () ? AI_V4MAPPED : 0)); } @@ -497,7 +498,7 @@ _nss_nisplus_gethostbyname_r (const char *name, struct hostent *host, char *buffer, size_t buflen, int *errnop, int *h_errnop) { - if (_res.options & RES_USE_INET6) + if (res_use_inet6 ()) { enum nss_status status; @@ -558,7 +559,7 @@ _nss_nisplus_gethostbyaddr_r (const void *addr, socklen_t addrlen, int af, parse_res = _nss_nisplus_parse_hostent (result, af, host, buffer, buflen, errnop, - ((_res.options & RES_USE_INET6) + (res_use_inet6 () ? AI_V4MAPPED : 0)); nis_freeresult (result); |