Check for an invalid hInternet handle in INET_QueryOptionHelper for
INTERNET_OPTION_PROXY before attempting to use it.
This commit is contained in:
parent
4722941695
commit
c2053e1ded
|
@ -1876,6 +1876,13 @@ static BOOL INET_QueryOptionHelper(BOOL bIsUnicode, HINTERNET hInternet, DWORD d
|
|||
{
|
||||
LPWININETAPPINFOW lpwai = (LPWININETAPPINFOW)lpwhh;
|
||||
|
||||
if (!lpwhh)
|
||||
{
|
||||
WARN("Invalid hInternet handle\n");
|
||||
SetLastError(ERROR_INVALID_HANDLE);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
if (bIsUnicode)
|
||||
{
|
||||
INTERNET_PROXY_INFOW *pPI = (INTERNET_PROXY_INFOW *)lpBuffer;
|
||||
|
|
Loading…
Reference in New Issue