[iphlpapi 1/2] Add support for GetTcpTable on Mac OS X

Jason Green jave27 at gmail.com
Tue Jul 10 23:19:38 CDT 2007


Original author: Mark Adams, TransGaming, Inc.
License: LGPL and/or MIT/X11

Changelog:
 - Add configure checks for Mac OS X specific headers and implement
GetTcpTable() for Mac.
-------------- next part --------------
From 9fe5cfb3ed87212c1f48cf671edc3a4d013fe3d1 Mon Sep 17 00:00:00 2001
From: Jason <jason at jave02.(none)>
Date: Tue, 10 Jul 2007 23:39:21 -0400
Subject: [PATCH] Add support for GetTcpTable on Mac OS X.

Original author: Mark Adams, TransGaming, Inc.
---
 configure.ac                  |   21 ++
 dlls/iphlpapi/iphlpapi_main.c |   25 +-
 dlls/iphlpapi/ipstats.c       |  424 ++++++++++++++++++++++++++++++-----------
 dlls/iphlpapi/ipstats.h       |    3 
 include/config.h.in           |   12 +
 5 files changed, 350 insertions(+), 135 deletions(-)

diff --git a/configure.ac b/configure.ac
index 01165a0..bec2743 100644
--- a/configure.ac
+++ b/configure.ac
@@ -249,6 +249,7 @@ AC_CHECK_HEADERS(\
 	sys/shm.h \
 	sys/signal.h \
 	sys/socket.h \
+	sys/socketvar.h \
 	sys/sockio.h \
 	sys/soundcard.h \
 	sys/statvfs.h \
@@ -278,11 +279,29 @@ AC_CHECK_HEADERS([sys/mount.h sys/statfs
      # include <sys/param.h>
      #endif])
 
-AC_CHECK_HEADERS([net/if.h net/if_arp.h net/if_dl.h net/if_types.h net/route.h netipx/ipx.h],,,
+AC_CHECK_HEADERS([netinet/in_pcb.h netinet/ip_var.h net/if.h net/if_arp.h net/if_dl.h net/if_types.h net/route.h resolv.h],,,
     [#include <sys/types.h>
      #if HAVE_SYS_SOCKET_H
      # include <sys/socket.h>
      #endif])
+     #if HAVE_SYS_SOCKETVAR_H
+     # include <sys/socketvar.h>
+     #endif
+
+AC_CHECK_HEADERS([netinet/tcp_var.h],,,
+    [#include <sys/types.h>
+     #if HAVE_SYS_SOCKET_H
+     # include <sys/socket.h>
+     #endif
+     #if HAVE_SYS_SOCKETVAR_H
+     # include <sys/socketvar.h>
+     #endif
+     #if HAVE_NETINET_IN_H
+     # include <netinet/in.h>
+     #endif
+     #ifdef HAVE_NETINET_TCP_H
+     # include <netinet/tcp.h>
+     #endif])
 
 AC_CHECK_HEADERS([linux/ipx.h],,,
     [#include <sys/types.h>
diff --git a/dlls/iphlpapi/iphlpapi_main.c b/dlls/iphlpapi/iphlpapi_main.c
index 6b7fa62..799f7fc 100644
--- a/dlls/iphlpapi/iphlpapi_main.c
+++ b/dlls/iphlpapi/iphlpapi_main.c
@@ -336,7 +336,9 @@ DWORD WINAPI AllocateAndGetTcpTableFromS
 
   TRACE("ppTcpTable %p, bOrder %d, heap %p, flags 0x%08x\n",
    ppTcpTable, bOrder, heap, flags);
-  ret = getTcpTable(ppTcpTable, heap, flags);
+
+  *ppTcpTable = NULL;
+  ret = getTcpTable(ppTcpTable, 0, heap, flags);
   if (!ret && bOrder)
     qsort((*ppTcpTable)->table, (*ppTcpTable)->dwNumEntries,
      sizeof(MIB_TCPROW), TcpTableSorter);
@@ -1545,25 +1547,16 @@ DWORD WINAPI GetTcpTable(PMIB_TCPTABLE p
       ret = ERROR_INSUFFICIENT_BUFFER;
     }
     else {
-      PMIB_TCPTABLE table;
-
-      ret = getTcpTable(&table, GetProcessHeap(), 0);
+      ret = getTcpTable(&pTcpTable, numEntries, 0, 0);
       if (!ret) {
-        size = sizeof(MIB_TCPTABLE) + (table->dwNumEntries - 1) *
+        size = sizeof(MIB_TCPTABLE) + (pTcpTable->dwNumEntries - 1) *
          sizeof(MIB_TCPROW);
-        if (*pdwSize < size) {
-          *pdwSize = size;
-          ret = ERROR_INSUFFICIENT_BUFFER;
-        }
-        else {
-          *pdwSize = size;
-          memcpy(pTcpTable, table, size);
+        *pdwSize = size;
+
           if (bOrder)
-            qsort(pTcpTable->table, pTcpTable->dwNumEntries,
-             sizeof(MIB_TCPROW), TcpTableSorter);
+             qsort(pTcpTable->table, pTcpTable->dwNumEntries,
+                   sizeof(MIB_TCPROW), TcpTableSorter);
           ret = NO_ERROR;
-        }
-        HeapFree(GetProcessHeap(), 0, table);
       }
       else
         ret = ERROR_OUTOFMEMORY;
diff --git a/dlls/iphlpapi/ipstats.c b/dlls/iphlpapi/ipstats.c
index b80cf61..874a0d5 100644
--- a/dlls/iphlpapi/ipstats.c
+++ b/dlls/iphlpapi/ipstats.c
@@ -1,4 +1,5 @@
 /* Copyright (C) 2003,2006 Juan Lang
+ * Copyright (C) 2007 TransGaming Technologies Inc.
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public
@@ -30,6 +31,9 @@ #include <sys/types.h>
 #ifdef HAVE_SYS_SOCKET_H
 #include <sys/socket.h>
 #endif
+#ifdef HAVE_SYS_SOCKETVAR_H
+#include <sys/socketvar.h>
+#endif
 #ifdef HAVE_NETINET_IN_H
 #include <netinet/in.h>
 #endif
@@ -52,13 +56,27 @@ #ifdef HAVE_NETINET_TCP_FSM_H
 #include <netinet/tcp_fsm.h>
 #endif
 
-#ifdef HAVE_SYS_SYSCTL_H
+#ifdef HAVE_NETINET_IN_PCB_H
+#include <netinet/in_pcb.h>
+#endif
+#ifdef HAVE_NETINET_TCP_VAR_H
+#include <netinet/tcp_var.h>
+#endif
+#ifdef HAVE_NETINET_IP_VAR_H
+#include <netinet/ip_var.h>
+#endif
+
+ #ifdef HAVE_SYS_SYSCTL_H
 #include <sys/sysctl.h>
 #endif
 
+#ifndef ROUNDUP
 #define ROUNDUP(a) \
 	((a) > 0 ? (1 + (((a) - 1) | (sizeof(long) - 1))) : sizeof(long))
+#endif
+#ifndef ADVANCE
 #define ADVANCE(x, n) (x += ROUNDUP(((struct sockaddr *)n)->sa_len))
+#endif
 
 #include "windef.h"
 #include "winbase.h"
@@ -66,7 +84,7 @@ #include "iprtrmib.h"
 #include "ifenum.h"
 #include "ipstats.h"
 
-#ifdef linux
+#ifndef HAVE_NETINET_TCP_FSM_H
 #define TCPS_ESTABLISHED  1
 #define TCPS_SYN_SENT     2
 #define TCPS_SYN_RECEIVED 3
@@ -564,6 +582,100 @@ DWORD getUDPStats(MIB_UDPSTATS *stats)
 
 static DWORD getNumWithOneHeader(const char *filename)
 {
+#if defined(HAVE_SYS_SYSCTL_H) && defined(HAVE_NETINET_IN_PCB_H)
+   size_t Len = 0;
+   char *Buf;
+   struct xinpgen *pXIG, *pOrigXIG;
+   int Protocol;
+   DWORD NumEntries = 0;
+
+   if (!strcmp (filename, "net.inet.tcp.pcblist"))
+      Protocol = IPPROTO_TCP;
+   else if (!strcmp (filename, "net.inet.udp.pcblist"))
+      Protocol = IPPROTO_UDP;
+   else
+   {
+      ERR ("Unsupported mib '%s', needs protocol mapping\n",
+           filename);
+      return 0;
+   }
+
+   if (sysctlbyname (filename, NULL, &Len, NULL, 0) < 0)
+   {
+      WARN ("Unable to read '%s' via sysctlbyname\n", filename);
+      return 0;
+   }
+
+   Buf = HeapAlloc (GetProcessHeap (), 0, Len);
+   if (!Buf)
+   {
+      ERR ("Out of memory!\n");
+      return 0;
+   }
+
+   if (sysctlbyname (filename, Buf, &Len, NULL, 0) < 0)
+   {
+      ERR ("Failure to read '%s' via sysctlbyname!\n", filename);
+      HeapFree (GetProcessHeap (), 0, Buf);
+      return 0;
+   }
+
+   /* Might be nothing here; first entry is just a header it seems */
+   if (Len <= sizeof (struct xinpgen))
+   {
+      HeapFree (GetProcessHeap (), 0, Buf);
+      return 0;
+   }
+
+   pOrigXIG = (struct xinpgen *)Buf;
+   pXIG = pOrigXIG;
+
+   for (pXIG = (struct xinpgen *)((char *)pXIG + pXIG->xig_len);
+        pXIG->xig_len > sizeof (struct xinpgen);
+        pXIG = (struct xinpgen *)((char *)pXIG + pXIG->xig_len))
+   {
+      struct tcpcb *pTCPData = NULL;
+      struct inpcb *pINData;
+      struct xsocket *pSockData;
+
+      if (Protocol == IPPROTO_TCP)
+      {
+         pTCPData = &((struct xtcpcb *)pXIG)->xt_tp;
+         pINData = &((struct xtcpcb *)pXIG)->xt_inp;
+         pSockData = &((struct xtcpcb *)pXIG)->xt_socket;
+      }
+      else
+      {
+         pINData = &((struct xinpcb *)pXIG)->xi_inp;
+         pSockData = &((struct xinpcb *)pXIG)->xi_socket;
+      }
+
+      /* Ignore sockets for other protocols */
+      if (pSockData->xso_protocol != Protocol)
+         continue;
+
+      /* Ignore PCBs that were freed while generating the data */
+      if (pINData->inp_gencnt > pOrigXIG->xig_gen)
+         continue;
+
+      /* we're only interested in IPv4 addresses */
+      if (!(pINData->inp_vflag & INP_IPV4) ||
+          (pINData->inp_vflag & INP_IPV6))
+         continue;
+
+      /* If all 0's, skip it */
+      if (!pINData->inp_laddr.s_addr &&
+          !pINData->inp_lport &&
+          !pINData->inp_faddr.s_addr &&
+          !pINData->inp_fport)
+         continue;
+
+      NumEntries++;
+   }
+
+   HeapFree (GetProcessHeap (), 0, Buf);
+   return NumEntries;
+#else
   FILE *fp;
   int ret = 0;
 
@@ -586,6 +698,7 @@ static DWORD getNumWithOneHeader(const c
      ERR ("Unable to open '%s' to count entries!\n", filename);
 
   return ret;
+#endif
 }
 
 DWORD getNumRoutes(void)
@@ -1026,132 +1139,209 @@ #endif
   return ret;
 }
 
+
 DWORD getNumTcpEntries(void)
 {
-  return getNumWithOneHeader("/proc/net/tcp");
+#if defined(HAVE_SYS_SYSCTL_H) && defined(HAVE_NETINET_IN_PCB_H)
+   return getNumWithOneHeader ("net.inet.tcp.pcblist");
+#else
+   return getNumWithOneHeader ("/proc/net/tcp");
+#endif
 }
 
-DWORD getTcpTable(PMIB_TCPTABLE *ppTcpTable, HANDLE heap, DWORD flags)
+
+/* Why not a lookup table? Because the TCPS_* constants are different
+   on different platforms */
+static DWORD TCPStateToMIBState (int state)
 {
-  DWORD ret;
+   switch (state)
+   {
+      case TCPS_ESTABLISHED: return MIB_TCP_STATE_ESTAB;
+      case TCPS_SYN_SENT: return MIB_TCP_STATE_SYN_SENT;
+      case TCPS_SYN_RECEIVED: return MIB_TCP_STATE_SYN_RCVD;
+      case TCPS_FIN_WAIT_1: return MIB_TCP_STATE_FIN_WAIT1;
+      case TCPS_FIN_WAIT_2: return MIB_TCP_STATE_FIN_WAIT2;
+      case TCPS_TIME_WAIT: return MIB_TCP_STATE_TIME_WAIT;
+      case TCPS_CLOSE_WAIT: return MIB_TCP_STATE_CLOSE_WAIT;
+      case TCPS_LAST_ACK: return MIB_TCP_STATE_LAST_ACK;
+      case TCPS_LISTEN: return MIB_TCP_STATE_LISTEN;
+      case TCPS_CLOSING: return MIB_TCP_STATE_CLOSING;
+      default:
+      case TCPS_CLOSED: return MIB_TCP_STATE_CLOSED;
+   }
+}
 
-#if defined(HAVE_SYS_SYSCTL_H) && defined(NET_RT_DUMP)
-  ERR ("unimplemented!\n");
-  return ERROR_INVALID_PARAMETER;
+
+DWORD getTcpTable(PMIB_TCPTABLE *ppTcpTable, DWORD maxEntries, HANDLE heap,
+                  DWORD flags)
+{
+   DWORD numEntries;
+   PMIB_TCPTABLE table;
+#if defined(HAVE_SYS_SYSCTL_H) && defined(HAVE_NETINET_IN_PCB_H)
+   size_t Len = 0;
+   char *Buf;
+   struct xinpgen *pXIG, *pOrigXIG;
+#else
+   FILE *fp;
+   char buf[512] = { 0 }, *ptr;
 #endif
 
-  if (!ppTcpTable)
-    ret = ERROR_INVALID_PARAMETER;
-  else {
-    DWORD numEntries = getNumTcpEntries();
-    PMIB_TCPTABLE table = HeapAlloc(heap, flags,
-     sizeof(MIB_TCPTABLE) + (numEntries - 1) * sizeof(MIB_TCPROW));
+   if (!ppTcpTable)
+      return ERROR_INVALID_PARAMETER;
+  
+   numEntries = getNumTcpEntries ();
 
-    if (table) {
-      FILE *fp;
+   if (!*ppTcpTable)
+   {
+      *ppTcpTable = HeapAlloc (heap, flags,
+                               sizeof (MIB_TCPTABLE) +
+                               (numEntries - 1) * sizeof (MIB_TCPROW));
+      if (!*ppTcpTable)
+      {
+         ERR ("Out of memory!\n");
+         return ERROR_OUTOFMEMORY;
+      }
+      maxEntries = numEntries;
+   }
 
-      ret = NO_ERROR;
-      *ppTcpTable = table;
-      table->dwNumEntries = 0;
-      /* get from /proc/net/tcp, no error if can't */
-      fp = fopen("/proc/net/tcp", "r");
-      if (fp) {
-        char buf[512] = { 0 }, *ptr;
+   table = *ppTcpTable;
+   table->dwNumEntries = 0;
+   if (!numEntries)
+      return NO_ERROR;
 
-        /* skip header line */
-        ptr = fgets(buf, sizeof(buf), fp);
-        while (ptr && table->dwNumEntries < numEntries) {
-          memset(&table->table[table->dwNumEntries], 0, sizeof(MIB_TCPROW));
-          ptr = fgets(buf, sizeof(buf), fp);
-          if (ptr) {
-            char *endPtr;
+#if defined(HAVE_SYS_SYSCTL_H) && defined(HAVE_NETINET_IN_PCB_H)
 
-            while (ptr && *ptr && *ptr != ':')
-              ptr++;
-            if (ptr && *ptr)
-              ptr++;
-            if (ptr && *ptr) {
-              table->table[table->dwNumEntries].dwLocalAddr = strtoul(ptr,
-               &endPtr, 16);
-              ptr = endPtr;
-            }
-            if (ptr && *ptr) {
-              ptr++;
-              table->table[table->dwNumEntries].dwLocalPort = strtoul(ptr,
-               &endPtr, 16);
-              ptr = endPtr;
-            }
-            if (ptr && *ptr) {
-              table->table[table->dwNumEntries].dwRemoteAddr = strtoul(ptr,
-               &endPtr, 16);
-              ptr = endPtr;
-            }
-            if (ptr && *ptr) {
-              ptr++;
-              table->table[table->dwNumEntries].dwRemotePort = strtoul(ptr,
-               &endPtr, 16);
-              ptr = endPtr;
-            }
-            if (ptr && *ptr) {
-              DWORD state = strtoul(ptr, &endPtr, 16);
-
-              switch (state)
-              {
-                case TCPS_ESTABLISHED:
-                  table->table[table->dwNumEntries].dwState =
-                   MIB_TCP_STATE_ESTAB;
-                  break;
-                case TCPS_SYN_SENT:
-                  table->table[table->dwNumEntries].dwState =
-                   MIB_TCP_STATE_SYN_SENT;
-                  break;
-                case TCPS_SYN_RECEIVED:
-                  table->table[table->dwNumEntries].dwState =
-                   MIB_TCP_STATE_SYN_RCVD;
-                  break;
-                case TCPS_FIN_WAIT_1:
-                  table->table[table->dwNumEntries].dwState =
-                   MIB_TCP_STATE_FIN_WAIT1;
-                  break;
-                case TCPS_FIN_WAIT_2:
-                  table->table[table->dwNumEntries].dwState =
-                   MIB_TCP_STATE_FIN_WAIT2;
-                  break;
-                case TCPS_TIME_WAIT:
-                  table->table[table->dwNumEntries].dwState =
-                   MIB_TCP_STATE_TIME_WAIT;
-                  break;
-                case TCPS_CLOSED:
-                  table->table[table->dwNumEntries].dwState =
-                   MIB_TCP_STATE_CLOSED;
-                  break;
-                case TCPS_CLOSE_WAIT:
-                  table->table[table->dwNumEntries].dwState =
-                   MIB_TCP_STATE_CLOSE_WAIT;
-                  break;
-                case TCPS_LAST_ACK:
-                  table->table[table->dwNumEntries].dwState =
-                   MIB_TCP_STATE_LAST_ACK;
-                  break;
-                case TCPS_LISTEN:
-                  table->table[table->dwNumEntries].dwState =
-                   MIB_TCP_STATE_LISTEN;
-                  break;
-                case TCPS_CLOSING:
-                  table->table[table->dwNumEntries].dwState =
-                   MIB_TCP_STATE_CLOSING;
-                  break;
-              }
-              ptr = endPtr;
-            }
-            table->dwNumEntries++;
-          }
-        }
-        fclose(fp);
+   if (sysctlbyname ("net.inet.tcp.pcblist", NULL, &Len, NULL, 0) < 0)
+   {
+      ERR ("Failure to read net.inet.tcp.pcblist via sysctlbyname!\n");
+      return ERROR_OUTOFMEMORY;
+   }
+
+   Buf = HeapAlloc (GetProcessHeap (), 0, Len);
+   if (!Buf)
+   {
+      ERR ("Out of memory!\n");
+      return ERROR_OUTOFMEMORY;
+   }
+
+   if (sysctlbyname ("net.inet.tcp.pcblist", Buf, &Len, NULL, 0) < 0)
+   { 
+      ERR ("Failure to read net.inet.tcp.pcblist via sysctlbyname!\n");
+      HeapFree (GetProcessHeap (), 0, Buf);
+      return ERROR_OUTOFMEMORY;
+   }
+
+   /* Might be nothing here; first entry is just a header it seems */
+   if (Len <= sizeof (struct xinpgen))
+   {
+      HeapFree (GetProcessHeap (), 0, Buf);
+      return NO_ERROR;
+   }
+
+   pOrigXIG = (struct xinpgen *)Buf;
+   pXIG = pOrigXIG;
+
+   for (pXIG = (struct xinpgen *)((char *)pXIG + pXIG->xig_len);
+        (pXIG->xig_len > sizeof (struct xinpgen)) &&
+           (table->dwNumEntries < maxEntries);
+        pXIG = (struct xinpgen *)((char *)pXIG + pXIG->xig_len))
+   {
+      struct tcpcb *pTCPData = NULL;
+      struct inpcb *pINData;
+      struct xsocket *pSockData;
+
+      pTCPData = &((struct xtcpcb *)pXIG)->xt_tp;
+      pINData = &((struct xtcpcb *)pXIG)->xt_inp;
+      pSockData = &((struct xtcpcb *)pXIG)->xt_socket;
+
+      /* Ignore sockets for other protocols */
+      if (pSockData->xso_protocol != IPPROTO_TCP)
+         continue;
+
+      /* Ignore PCBs that were freed while generating the data */
+      if (pINData->inp_gencnt > pOrigXIG->xig_gen)
+         continue;
+
+      /* we're only interested in IPv4 addresses */
+      if (!(pINData->inp_vflag & INP_IPV4) ||
+          (pINData->inp_vflag & INP_IPV6))
+         continue;
+
+      /* If all 0's, skip it */
+      if (!pINData->inp_laddr.s_addr &&
+          !pINData->inp_lport &&
+          !pINData->inp_faddr.s_addr &&
+          !pINData->inp_fport)
+         continue;
+
+      /* Fill in structure details */
+      table->table[table->dwNumEntries].dwLocalAddr =
+         pINData->inp_laddr.s_addr;
+      table->table[table->dwNumEntries].dwLocalPort =
+         pINData->inp_lport;
+      table->table[table->dwNumEntries].dwRemoteAddr =
+         pINData->inp_faddr.s_addr;
+      table->table[table->dwNumEntries].dwRemotePort =
+         pINData->inp_fport;
+      table->table[table->dwNumEntries].dwState =
+         TCPStateToMIBState (pTCPData->t_state);
+
+      table->dwNumEntries++;
+   }
+
+   HeapFree (GetProcessHeap (), 0, Buf);
+#else
+   /* get from /proc/net/tcp, no error if can't */
+   fp = fopen("/proc/net/tcp", "r");
+   if (!fp)
+      return NO_ERROR;
+
+   /* skip header line */
+   ptr = fgets(buf, sizeof(buf), fp);
+   while (ptr && table->dwNumEntries < maxEntries) {
+      memset(&table->table[table->dwNumEntries], 0, sizeof(MIB_TCPROW));
+      ptr = fgets(buf, sizeof(buf), fp);
+      if (ptr) {
+         char *endPtr;
+
+         while (ptr && *ptr && *ptr != ':')
+            ptr++;
+         if (ptr && *ptr)
+            ptr++;
+         if (ptr && *ptr) {
+            table->table[table->dwNumEntries].dwLocalAddr =
+               strtoul(ptr, &endPtr, 16);
+            ptr = endPtr;
+         }
+         if (ptr && *ptr) {
+            ptr++;
+            table->table[table->dwNumEntries].dwLocalPort =
+               strtoul(ptr, &endPtr, 16);
+            ptr = endPtr;
+         }
+         if (ptr && *ptr) {
+            table->table[table->dwNumEntries].dwRemoteAddr =
+               strtoul(ptr, &endPtr, 16);
+            ptr = endPtr;
+         }
+         if (ptr && *ptr) {
+            ptr++;
+            table->table[table->dwNumEntries].dwRemotePort =
+               strtoul(ptr, &endPtr, 16);
+            ptr = endPtr;
+         }
+         if (ptr && *ptr) {
+            DWORD state = strtoul(ptr, &endPtr, 16);
+
+            table->table[table->dwNumEntries].dwState =
+               TCPStateToMIBState (state);
+            ptr = endPtr;
+         }
+         table->dwNumEntries++;
       }
-    }
-    else
-      ret = ERROR_OUTOFMEMORY;
-  }
-  return ret;
+   }
+   fclose(fp);
+#endif
+
+   return NO_ERROR;
 }
diff --git a/dlls/iphlpapi/ipstats.h b/dlls/iphlpapi/ipstats.h
index 147276e..ec8dcb0 100644
--- a/dlls/iphlpapi/ipstats.h
+++ b/dlls/iphlpapi/ipstats.h
@@ -83,6 +83,7 @@ DWORD getNumTcpEntries(void);
 /* Allocates the TCP state table from heap and returns it to you in *ppTcpTable.
  * Returns NO_ERROR on success, something else on failure.
  */
-DWORD getTcpTable(PMIB_TCPTABLE *ppTcpTable, HANDLE heap, DWORD flags);
+DWORD getTcpTable(PMIB_TCPTABLE *ppTcpTable, DWORD maxEntries, HANDLE heap,
+                  DWORD flags);
 
 #endif /* ndef WINE_IPSTATS_H_ */
diff --git a/include/config.h.in b/include/config.h.in
index 807d365..b51d0a2 100644
--- a/include/config.h.in
+++ b/include/config.h.in
@@ -426,15 +426,24 @@ #undef HAVE_NETDB_H
 /* Define to 1 if you have the <netinet/in.h> header file. */
 #undef HAVE_NETINET_IN_H
 
+/* Define to 1 if you have the <netinet/in_pcb.h> header file. */
+#undef HAVE_NETINET_IN_PCB_H
+
 /* Define to 1 if you have the <netinet/in_systm.h> header file. */
 #undef HAVE_NETINET_IN_SYSTM_H
 
+/* Define to 1 if you have the <netinet/ip_var.h> header file. */
+#undef HAVE_NETINET_IP_VAR_H
+
 /* Define to 1 if you have the <netinet/tcp_fsm.h> header file. */
 #undef HAVE_NETINET_TCP_FSM_H
 
 /* Define to 1 if you have the <netinet/tcp.h> header file. */
 #undef HAVE_NETINET_TCP_H
 
+/* Define to 1 if you have the <netinet/tcp_var.h> header file. */
+#undef HAVE_NETINET_TCP_VAR_H
+
 /* Define to 1 if you have the <netipx/ipx.h> header file. */
 #undef HAVE_NETIPX_IPX_H
 
@@ -777,6 +786,9 @@ #undef HAVE_SYS_SHM_H
 /* Define to 1 if you have the <sys/signal.h> header file. */
 #undef HAVE_SYS_SIGNAL_H
 
+/* Define to 1 if you have the <sys/socketvar.h> header file. */
+#undef HAVE_SYS_SOCKETVAR_H
+
 /* Define to 1 if you have the <sys/socket.h> header file. */
 #undef HAVE_SYS_SOCKET_H
 
-- 
1.4.1


More information about the wine-patches mailing list