diff options
author | trawick <trawick@13f79535-47bb-0310-9956-ffa450edef68> | 2003-12-23 14:33:16 +0000 |
---|---|---|
committer | trawick <trawick@13f79535-47bb-0310-9956-ffa450edef68> | 2003-12-23 14:33:16 +0000 |
commit | bbddad2a2cec6b8a27d2ce6042913dafc64775d3 (patch) | |
tree | a5a9cf0c39123e80689373ac0ad794231a074148 /build | |
parent | 468f159abf673c01818dfb26a575b547f62889a4 (diff) | |
download | libapr-bbddad2a2cec6b8a27d2ce6042913dafc64775d3.tar.gz |
fix a false failure with APR_CHECK_GETNAMEINFO_IPV4_MAPPED on z/OS
- NI_MAXHOST is not defined, so provide fall-back logic
(we could just skip NI_MAXHOST altogether, but showing the
fallback will remind folks of why we can't just use NI_MAXHOST)
- htonl is a macro in arpa/inet.h, so include that header so that
the link is successful
git-svn-id: http://svn.apache.org/repos/asf/apr/apr/branches/APR_0_9_BRANCH@64844 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'build')
-rw-r--r-- | build/apr_network.m4 | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/build/apr_network.m4 b/build/apr_network.m4 index f37e25c0d..f227bbefb 100644 --- a/build/apr_network.m4 +++ b/build/apr_network.m4 @@ -164,11 +164,18 @@ AC_DEFUN(APR_CHECK_GETNAMEINFO_IPV4_MAPPED,[ #ifdef HAVE_NETINET_IN_H #include <netinet/in.h> #endif +#ifdef HAVE_ARPA_INET_H +#include <arpa/inet.h> +#endif void main(void) { struct sockaddr_in6 sa = {0}; struct in_addr ipv4; +#if defined(NI_MAXHOST) char hbuf[NI_MAXHOST]; +#else + char hbuf[256]; +#endif unsigned int *addr32; int error; |