ws2_32: Pass NULL nodename on to native getaddrinfo.
This commit is contained in:
parent
ad5340f63a
commit
8e5d5bf58a
|
@ -4824,14 +4824,15 @@ int WINAPI WS_getaddrinfo(LPCSTR nodename, LPCSTR servname, const struct WS_addr
|
||||||
if (!nodename && !servname) return WSAHOST_NOT_FOUND;
|
if (!nodename && !servname) return WSAHOST_NOT_FOUND;
|
||||||
|
|
||||||
if (!nodename)
|
if (!nodename)
|
||||||
node = "localhost";
|
node = NULL;
|
||||||
else if (!nodename[0])
|
else if (!nodename[0])
|
||||||
|
{
|
||||||
node = hostname = get_hostname();
|
node = hostname = get_hostname();
|
||||||
|
if (!node) return WSA_NOT_ENOUGH_MEMORY;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
node = nodename;
|
node = nodename;
|
||||||
|
|
||||||
if (!node) return WSA_NOT_ENOUGH_MEMORY;
|
|
||||||
|
|
||||||
if (hints) {
|
if (hints) {
|
||||||
punixhints = &unixhints;
|
punixhints = &unixhints;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue