mirror of
https://github.com/asterisk/asterisk.git
synced 2025-10-12 15:45:18 +00:00
(closes issue #10383)
Reported by: rizzo Include stdlib.h so NULL gets defined for gethostbyname_r checks. git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@78166 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -266,7 +266,8 @@ AC_SEARCH_LIBS(gethostbyname_r, [socket nsl])
|
||||
|
||||
AC_MSG_CHECKING(for gethostbyname_r with 6 arguments)
|
||||
AC_LINK_IFELSE(
|
||||
AC_LANG_PROGRAM([#include <netdb.h>],
|
||||
AC_LANG_PROGRAM([#include <stdlib.h>
|
||||
#include <netdb.h>],
|
||||
[struct hostent *he = gethostbyname_r((const char *)NULL, (struct hostent *)NULL, (char *)NULL, (int)0, (struct hostent **)NULL, (int *)NULL);]),
|
||||
AC_MSG_RESULT(yes)
|
||||
AC_DEFINE([HAVE_GETHOSTBYNAME_R_6], 1, [Define to 1 if your system has gethostbyname_r with 6 arguments.]),
|
||||
@@ -275,7 +276,8 @@ AC_LINK_IFELSE(
|
||||
|
||||
AC_MSG_CHECKING(for gethostbyname_r with 5 arguments)
|
||||
AC_LINK_IFELSE(
|
||||
AC_LANG_PROGRAM([#include <netdb.h>],
|
||||
AC_LANG_PROGRAM([#include <stdlib.h>
|
||||
#include <netdb.h>],
|
||||
[struct hostent *he = gethostbyname_r((const char *)NULL, (struct hostent *)NULL, (char *)NULL, (int)0, (int *)NULL);]),
|
||||
AC_MSG_RESULT(yes)
|
||||
AC_DEFINE([HAVE_GETHOSTBYNAME_R_5], 1, [Define to 1 if your system has gethostbyname_r with 5 arguments.]),
|
||||
|
Reference in New Issue
Block a user