Jacek Caban : wininet: Use lpHttpSession instead of lpwhcalback where possible.
Module: wine Branch: master Commit: 61a1cef6f65dbd2da6d92913060206d043f96e90 URL: http://source.winehq.org/git/wine.git/?a=commit;h=61a1cef6f65dbd2da6d9291306... Author: Jacek Caban <jacek(a)codeweavers.com> Date: Sun Oct 29 18:51:15 2006 +0100 wininet: Use lpHttpSession instead of lpwhcalback where possible. --- dlls/wininet/dialogs.c | 4 ++-- dlls/wininet/http.c | 14 +++++++------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/dlls/wininet/dialogs.c b/dlls/wininet/dialogs.c index 2eae034..fc95762 100644 --- a/dlls/wininet/dialogs.c +++ b/dlls/wininet/dialogs.c @@ -68,7 +68,7 @@ static BOOL WININET_GetProxyServer( HINT if (NULL == lpwhr) return FALSE; - lpwhs = (LPWININETHTTPSESSIONW) lpwhr->hdr.lpwhparent; + lpwhs = lpwhr->lpHttpSession; if (NULL == lpwhs) return FALSE; @@ -209,7 +209,7 @@ static BOOL WININET_SetProxyAuthorizatio if( !lpwhr ) return FALSE; - lpwhs = (LPWININETHTTPSESSIONW) lpwhr->hdr.lpwhparent; + lpwhs = lpwhr->lpHttpSession; if (NULL == lpwhs || lpwhs->hdr.htype != WH_HHTTPSESSION) { INTERNET_SetLastError(ERROR_INTERNET_INCORRECT_HANDLE_TYPE); diff --git a/dlls/wininet/http.c b/dlls/wininet/http.c index cfbda27..3ae442e 100644 --- a/dlls/wininet/http.c +++ b/dlls/wininet/http.c @@ -372,7 +372,7 @@ static void HTTP_ProcessHeaders( LPWININ static void HTTP_AddProxyInfo( LPWININETHTTPREQW lpwhr ) { - LPWININETHTTPSESSIONW lpwhs = (LPWININETHTTPSESSIONW)lpwhr->hdr.lpwhparent; + LPWININETHTTPSESSIONW lpwhs = lpwhr->lpHttpSession; LPWININETAPPINFOW hIC = lpwhs->lpAppInfo; assert(lpwhs->hdr.htype == WH_HHTTPSESSION); @@ -1761,7 +1761,7 @@ BOOL WINAPI HttpSendRequestExW(HINTERNET return FALSE; } - lpwhs = (LPWININETHTTPSESSIONW) lpwhr->hdr.lpwhparent; + lpwhs = lpwhr->lpHttpSession; assert(lpwhs->hdr.htype == WH_HHTTPSESSION); hIC = lpwhs->lpAppInfo; assert(hIC->hdr.htype == WH_HINIT); @@ -1845,7 +1845,7 @@ BOOL WINAPI HttpSendRequestW(HINTERNET h goto lend; } - lpwhs = (LPWININETHTTPSESSIONW) lpwhr->hdr.lpwhparent; + lpwhs = lpwhr->lpHttpSession; if (NULL == lpwhs || lpwhs->hdr.htype != WH_HHTTPSESSION) { INTERNET_SetLastError(ERROR_INTERNET_INCORRECT_HANDLE_TYPE); @@ -1932,7 +1932,7 @@ static BOOL HTTP_HandleRedirect(LPWININE DWORD dwHeaderLength, LPVOID lpOptional, DWORD dwOptionalLength, DWORD dwContentLength) { - LPWININETHTTPSESSIONW lpwhs = (LPWININETHTTPSESSIONW) lpwhr->hdr.lpwhparent; + LPWININETHTTPSESSIONW lpwhs = lpwhr->lpHttpSession; LPWININETAPPINFOW hIC = lpwhs->lpAppInfo; WCHAR path[2048]; char szaddr[32]; @@ -2174,7 +2174,7 @@ static BOOL HTTP_SecureProxyConnect(LPWI BOOL ret; static const WCHAR szConnect[] = {'C','O','N','N','E','C','T',0}; static const WCHAR szFormat[] = {'%','s',':','%','d',0}; - LPWININETHTTPSESSIONW lpwhs = (LPWININETHTTPSESSIONW)lpwhr->hdr.lpwhparent; + LPWININETHTTPSESSIONW lpwhs = lpwhr->lpHttpSession; TRACE("\n"); @@ -2485,7 +2485,7 @@ static BOOL HTTP_OpenConnection(LPWININE goto lend; } - lpwhs = (LPWININETHTTPSESSIONW)lpwhr->hdr.lpwhparent; + lpwhs = lpwhr->lpHttpSession; hIC = lpwhs->lpAppInfo; inet_ntop(lpwhs->socketAddress.sin_family, &lpwhs->socketAddress.sin_addr, @@ -2912,7 +2912,7 @@ static VOID HTTP_CloseConnection(LPWININ TRACE("%p\n",lpwhr); - lpwhs = (LPWININETHTTPSESSIONW) lpwhr->hdr.lpwhparent; + lpwhs = lpwhr->lpHttpSession; hIC = lpwhs->lpAppInfo; INTERNET_SendCallback(&lpwhr->hdr, lpwhr->hdr.dwContext,
participants (1)
-
Alexandre Julliard