wininet: Error out if hInternet is a bad handle.

This commit is contained in:
James Hawkins 2006-07-03 14:08:11 -07:00 committed by Alexandre Julliard
parent 8e96015ebb
commit 545309c97f
1 changed files with 5 additions and 0 deletions

View File

@ -1989,6 +1989,11 @@ static BOOL INET_QueryOptionHelper(BOOL bIsUnicode, HINTERNET hInternet, DWORD d
TRACE("(%p, 0x%08lx, %p, %p)\n", hInternet, dwOption, lpBuffer, lpdwBufferLength);
lpwhh = (LPWININETHANDLEHEADER) WININET_GetObject( hInternet );
if (!lpwhh)
{
SetLastError(ERROR_INVALID_PARAMETER);
return FALSE;
}
switch (dwOption)
{