mirror of
https://github.com/ApfelTeeSaft/reactos.git
synced 2026-09-02 12:23:31 +00:00
[DNSAPI]
Properly check for domain name being set CID 1401070 svn path=/trunk/; revision=73842
This commit is contained in:
@@ -738,7 +738,7 @@ DnsQuery_W(LPCWSTR Name,
|
||||
TempLen += StringLength;
|
||||
HostWithDomainName = (PCHAR)RtlAllocateHeap(RtlGetProcessHeap(), 0, TempLen);
|
||||
StringCchCopyA(HostWithDomainName, TempLen, network_info->HostName);
|
||||
if (network_info->DomainName)
|
||||
if (network_info->DomainName[0])
|
||||
{
|
||||
StringCchCatA(HostWithDomainName, TempLen, ".");
|
||||
StringCchCatA(HostWithDomainName, TempLen, network_info->DomainName);
|
||||
@@ -783,7 +783,7 @@ DnsQuery_W(LPCWSTR Name,
|
||||
if ((addr.s_addr != INADDR_ANY) && (addr.s_addr != INADDR_NONE))
|
||||
adns_addserver(astate, addr);
|
||||
}
|
||||
if (network_info->DomainName)
|
||||
if (network_info->DomainName[0])
|
||||
{
|
||||
adns_ccf_search(astate, "LOCALDOMAIN", -1, network_info->DomainName);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user