其中:
typedef struct ip_interface_name_info {
ULONG Index; // Interface Index
ULONG MediaType; // Interface Types - see ipifcons.h
UCHAR ConnectionType;
UCHAR AccessType;
GUID DeviceGuid; // Device GUID is the guid of the device
// that IP exposes
GUID InterfaceGuid; // Interface GUID, if not GUID_NULL is the
// GUID for the interface mapped to the device.
} IP_INTERFACE_NAME_INFO, *PIP_INTERFACE_NAME_INFO;
这两个都应该是windows 的IPHLPAPI.DLL中的函数,其中第二个的C定义为(第一个没找到)
DWORD
WINAPI
NhpAllocateAndGetInterfaceInfoFromStack(
OUT IP_INTERFACE_NAME_INFO **ppTable,
OUT PDWORD pdwCount,
IN BOOL bOrder,
IN HANDLE hHeap,
IN DWORD dwFlags
);