Fix sa_len detection on FreeBSD.

FreeBSD requires socket.h to be included when testing if struct
sockaddr contains sa_len.

Change-Id: Ibe18a88ce19a4e8487bb00d7fa822a380ec8c98d
Reviewed-on: https://code.wireshark.org/review/17008
Reviewed-by: Michael Tüxen <tuexen@wireshark.org>
This commit is contained in:
Michael Tuexen 2016-08-11 15:32:21 +02:00 committed by Michael Tüxen
parent 1dfa478b9e
commit 8260ec1ca7
1 changed files with 7 additions and 1 deletions

View File

@ -2331,7 +2331,13 @@ AC_CHECK_MEMBERS([struct stat.st_flags])
# We need to know whether "struct sockaddr" has an "sa_len" member
# for get_interface_list().
AC_CHECK_MEMBERS([struct sockaddr.sa_len])
AC_CHECK_MEMBERS([struct sockaddr.sa_len],,,
[#ifdef HAVE_SYS_TYPES_H
#include <sys/types.h>
#endif
#ifdef HAVE_SYS_SOCKET_H
#include <sys/socket.h>
#endif])
# We must know our byte order
AC_C_BIGENDIAN