when getting the DNS server etc.
Changelog for the c-ares project
+* August 21
+
+- Alfredo Tupone provided a fix for the Windows code in get_iphlpapi_dns_info()
+ when getting the DNS server etc.
+
* June 19
- Added some checks for the addrinfo structure.
size_t ip_size = sizeof("255.255.255.255,")-1;
size_t left = ret_size;
char *ret = ret_buf;
+ HRESULT res;
if (!fi)
return (0);
if (!GetNetworkParams)
goto quit;
- if ((*GetNetworkParams) (fi, &size) != ERROR_BUFFER_OVERFLOW)
+ res = (*GetNetworkParams) (fi, &size);
+ if ((res != ERROR_BUFFER_OVERFLOW) && (res != ERROR_SUCCESS))
goto quit;
fi = alloca (size);