about summary refs log tree commit diff
path: root/nscd/nscd_gethst_r.c
diff options
context:
space:
mode:
authorFlorian Weimer <fweimer@redhat.com>2016-10-04 11:52:10 +0200
committerFlorian Weimer <fweimer@redhat.com>2016-12-31 18:55:14 +0100
commitb76e065991ec01299225d9da90a627ebe6c1ac97 (patch)
treeac94cc82b134096975419ced320f6ed329130756 /nscd/nscd_gethst_r.c
parent5840c75c2d6a9b980d6789f2ca7d47a9fa067263 (diff)
downloadglibc-b76e065991ec01299225d9da90a627ebe6c1ac97.tar.gz
glibc-b76e065991ec01299225d9da90a627ebe6c1ac97.tar.xz
glibc-b76e065991ec01299225d9da90a627ebe6c1ac97.zip
resolv: Deprecate the "inet6" option and RES_USE_INET6 [BZ #19582]
Diffstat (limited to 'nscd/nscd_gethst_r.c')
-rw-r--r--nscd/nscd_gethst_r.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/nscd/nscd_gethst_r.c b/nscd/nscd_gethst_r.c
index 7448add041..820a2fe6f7 100644
--- a/nscd/nscd_gethst_r.c
+++ b/nscd/nscd_gethst_r.c
@@ -17,7 +17,7 @@
    <http://www.gnu.org/licenses/>.  */
 
 #include <errno.h>
-#include <resolv.h>
+#include <resolv/resolv-internal.h>
 #include <stdio.h>
 #include <string.h>
 #include <stdint.h>
@@ -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);