summaryrefslogtreecommitdiff
path: root/lib/arpa_inet.in.h
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2010-12-27 01:22:00 +0100
committerBruno Haible <bruno@clisp.org>2010-12-27 01:30:41 +0100
commit0e6072c19800f82647e65c1bd663766ffd497200 (patch)
treeacdd543d05e88d5a998930fb19d6c3ebcf73d947 /lib/arpa_inet.in.h
parented4ce96d94a37ea75eb39d6a05b79f0b334cd2d0 (diff)
downloadgnulib-0e6072c19800f82647e65c1bd663766ffd497200.tar.gz
inet_ntop, inet_pton: Ensure declaration on NonStop Kernel.
* lib/arpa_inet.in.h: On NonStop Kernel, include also <netdb.h>. * m4/arpa_inet_h.m4 (gl_HEADER_ARPA_INET): Likewise. * m4/inet_ntop.m4 (gl_PREREQ_INET_NTOP): Include also <netdb.h> when looking for the declaration. * m4/inet_pton.m4 (gl_PREREQ_INET_PTON): Likewise. * doc/posix-functions/inet_ntop.texi: Document the NonStop Kernel problem. * doc/posix-functions/inet_pton.texi: Likewise.
Diffstat (limited to 'lib/arpa_inet.in.h')
-rw-r--r--lib/arpa_inet.in.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/arpa_inet.in.h b/lib/arpa_inet.in.h
index cfbd977917..d5cf265712 100644
--- a/lib/arpa_inet.in.h
+++ b/lib/arpa_inet.in.h
@@ -34,6 +34,12 @@
# include <sys/socket.h>
#endif
+/* On NonStop Kernel, inet_ntop and inet_pton are declared in <netdb.h>.
+ But avoid namespace pollution on glibc systems. */
+#if defined __TANDEM && !defined __GLIBC__
+# include <netdb.h>
+#endif
+
#if @HAVE_ARPA_INET_H@
/* The include_next requires a split double-inclusion guard. */