wininet: Don't set the host port from the server port.

This works for direct connections but in case of proxy connections server
port and host port usually are different.
This commit is contained in:
Hans Leidekker 2008-03-30 19:17:31 +01:00 committed by Alexandre Julliard
parent 0ffe9f5207
commit e4c59c263d
1 changed files with 5 additions and 1 deletions

View File

@ -1960,7 +1960,11 @@ HINTERNET WINAPI HTTP_HttpOpenRequestW(LPWININETHTTPSESSIONW lpwhs,
lpwhs->nServerPort = (dwFlags & INTERNET_FLAG_SECURE ?
INTERNET_DEFAULT_HTTPS_PORT :
INTERNET_DEFAULT_HTTP_PORT);
lpwhs->nHostPort = lpwhs->nServerPort;
if (lpwhs->nHostPort == INTERNET_INVALID_PORT_NUMBER)
lpwhs->nHostPort = (dwFlags & INTERNET_FLAG_SECURE ?
INTERNET_DEFAULT_HTTPS_PORT :
INTERNET_DEFAULT_HTTP_PORT);
if (NULL != hIC->lpszProxy && hIC->lpszProxy[0] != 0)
HTTP_DealWithProxy( hIC, lpwhs, lpwhr );