diff options
author | Yang Tse <yangsita@gmail.com> | 2008-10-28 19:13:25 +0000 |
---|---|---|
committer | Yang Tse <yangsita@gmail.com> | 2008-10-28 19:13:25 +0000 |
commit | 0989cd358aae91067b20a37d45dca4a29696e37a (patch) | |
tree | 9c7832643c6603eec2e7ce312b40442968b75edf /acinclude.m4 | |
parent | 6e0739931d3627f378abaa109fea4e62bcca1673 (diff) | |
download | curl-0989cd358aae91067b20a37d45dca4a29696e37a.tar.gz |
Initial attempt to detect at configuration time if the getaddrinfo()
function returns an addrinfo with an unfreeable ai_addr member ptr.
Diffstat (limited to 'acinclude.m4')
-rw-r--r-- | acinclude.m4 | 42 |
1 files changed, 0 insertions, 42 deletions
diff --git a/acinclude.m4 b/acinclude.m4 index 8b10c0e50..93b47c819 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -2565,48 +2565,6 @@ AC_DEFUN([CURL_CHECK_FUNC_SELECT], [ ]) -dnl ************************************************************ -dnl check for working getaddrinfo() that works with AI_NUMERICHOST -dnl -AC_DEFUN([CURL_CHECK_WORKING_GETADDRINFO],[ - AC_CACHE_CHECK(for working getaddrinfo, ac_cv_working_getaddrinfo,[ - AC_TRY_RUN( [ -#include <netdb.h> -#include <sys/types.h> -#include <sys/socket.h> - -int main(void) -{ - struct addrinfo hints, *ai; - int error; - - memset(&hints, 0, sizeof(hints)); - hints.ai_flags = AI_NUMERICHOST; - hints.ai_family = AF_UNSPEC; - hints.ai_socktype = SOCK_STREAM; - error = getaddrinfo("127.0.0.1", "8080", &hints, &ai); - if (error) { - return 1; - } - return 0; -} -],[ - ac_cv_working_getaddrinfo="yes" -],[ - ac_cv_working_getaddrinfo="no" -],[ - ac_cv_working_getaddrinfo="yes" -])]) -if test "$ac_cv_working_getaddrinfo" = "yes"; then - AC_DEFINE(HAVE_GETADDRINFO, 1, [Define if getaddrinfo exists and works]) - AC_DEFINE(ENABLE_IPV6, 1, [Define if you want to enable IPv6 support]) - - IPV6_ENABLED=1 - AC_SUBST(IPV6_ENABLED) -fi -]) - - # This is only a temporary fix. This macro is here to replace the broken one # delivered by the automake project (including the 1.9.6 release). As soon as # they ship a working version we SHOULD remove this work-around. |