IP_ADAPTER_INFO AdapterInfo[16]; // Allocate information
DWORD dwBufLen = sizeof(AdapterInfo); // Save memory size of buffer
DWORD dwStatus = GetAdaptersInfo( AdapterInfo, &dwBufLen);
PIP_ADAPTER_INFO pAdapterInfo = AdapterInfo; // Contains pointer to
do {
if(strcmp(pAdapterInfo->IpAddressList.IpAddress.String,"0.0.0.0")!=0)
{
int a=0;
}
pAdapterInfo = pAdapterInfo->Next; // Progress through
// linked list
}
while(pAdapterInfo); // Terminate if last adapter
沒有留言:
張貼留言