Commit bc99d867 authored by André Hentschel's avatar André Hentschel Committed by Alexandre Julliard

iphlpapi: Check for struct icmpstat (for NetBSD).

parent 20dbe912
......@@ -14028,6 +14028,20 @@ _ACEOF
fi
ac_fn_c_check_member "$LINENO" "struct icmpstat" "icps_inhist" "ac_cv_member_struct_icmpstat_icps_inhist" "#ifdef HAVE_NETINET_ICMP_VAR
#include <netinet/icmp_var.h>
#endif
"
if test "x$ac_cv_member_struct_icmpstat_icps_inhist" = xyes; then :
cat >>confdefs.h <<_ACEOF
#define HAVE_STRUCT_ICMPSTAT_ICPS_INHIST 1
_ACEOF
fi
ac_fn_c_check_member "$LINENO" "struct icmpstat" "icps_outhist" "ac_cv_member_struct_icmpstat_icps_outhist" "#ifdef HAVE_SYS_TYPES_H
#include <sys/types.h>
#endif
......
......@@ -2282,6 +2282,12 @@ AC_CHECK_MEMBERS([ns_msg._msg_ptr],,,
# include <arpa/nameser.h>
#endif])
dnl Check for struct icmpstat
AC_CHECK_MEMBERS([struct icmpstat.icps_inhist],,,
[#ifdef HAVE_NETINET_ICMP_VAR
#include <netinet/icmp_var.h>
#endif])
dnl Check for struct icmpstat.icps_outhist
AC_CHECK_MEMBERS([struct icmpstat.icps_outhist],,,
[#ifdef HAVE_SYS_TYPES_H
......
......@@ -493,7 +493,7 @@ DWORD WINAPI GetIcmpStatistics(PMIB_ICMP stats)
}
if (kc) kstat_close( kc );
}
#elif defined(HAVE_SYS_SYSCTL_H) && defined(ICMPCTL_STATS)
#elif defined(HAVE_SYS_SYSCTL_H) && defined(ICMPCTL_STATS) && defined(HAVE_STRUCT_ICMPSTAT_ICPS_INHIST)
{
int mib[] = {CTL_NET, PF_INET, IPPROTO_ICMP, ICMPCTL_STATS};
#define MIB_LEN (sizeof(mib) / sizeof(mib[0]))
......
......@@ -791,6 +791,9 @@
/* Define to 1 if `direction' is a member of `struct ff_effect'. */
#undef HAVE_STRUCT_FF_EFFECT_DIRECTION
/* Define to 1 if `icps_inhist' is a member of `struct icmpstat'. */
#undef HAVE_STRUCT_ICMPSTAT_ICPS_INHIST
/* Define to 1 if `icps_outhist' is a member of `struct icmpstat'. */
#undef HAVE_STRUCT_ICMPSTAT_ICPS_OUTHIST
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment