winhttp: Initialize a return variable.

When getaddrinfo() failed in detect_autoproxyconfig_url_dns(),
an undefined variable is passed to WinHttpDetectAutoProxyConfigUrl(),
causing applications to receive a wrong url.

This is a regression from 4ad4173e3a.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=48349
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Zhiyi Zhang 2019-12-24 17:18:07 +08:00 committed by Alexandre Julliard
parent 59e52108d5
commit 80a8c8d259
1 changed files with 1 additions and 1 deletions

View File

@ -1427,7 +1427,7 @@ static WCHAR *build_wpad_url( const char *hostname, const struct addrinfo *ai )
static WCHAR *detect_autoproxyconfig_url_dns(void)
{
char *fqdn, *domain, *p;
WCHAR *ret;
WCHAR *ret = NULL;
if (!(fqdn = get_computer_name( ComputerNamePhysicalDnsFullyQualified ))) return NULL;
if (!(domain = get_computer_name( ComputerNamePhysicalDnsDomain )))