From 9efe083ec52ebe362ee54dfb35e8d7c8915c301e Mon Sep 17 00:00:00 2001 From: Rob Shearman Date: Fri, 12 Jan 2007 19:19:18 -0600 Subject: [PATCH] wininet: HTTP_HttpQueryInfoW deals with bytes, not characters so update the callers that have this wrong assumption. --- dlls/wininet/http.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dlls/wininet/http.c b/dlls/wininet/http.c index 9a2e739cd55..c4c8fe4793d 100644 --- a/dlls/wininet/http.c +++ b/dlls/wininet/http.c @@ -665,7 +665,7 @@ BOOL WINAPI HttpEndRequestW(HINTERNET hRequest, (dwCode==302 || dwCode==301)) { WCHAR szNewLocation[2048]; - dwBufferSize=2048; + dwBufferSize=sizeof(szNewLocation); if(HTTP_HttpQueryInfoW(lpwhr,HTTP_QUERY_LOCATION,szNewLocation,&dwBufferSize,NULL)) { static const WCHAR szGET[] = { 'G','E','T', 0 }; @@ -2373,7 +2373,7 @@ BOOL WINAPI HTTP_HttpSendRequestW(LPWININETHTTPREQW lpwhr, LPCWSTR lpszHeaders, { DWORD dwCode,dwCodeLength=sizeof(DWORD); WCHAR szNewLocation[2048]; - dwBufferSize=2048; + dwBufferSize=sizeof(szNewLocation); if (HTTP_HttpQueryInfoW(lpwhr,HTTP_QUERY_FLAG_NUMBER|HTTP_QUERY_STATUS_CODE,&dwCode,&dwCodeLength,NULL) && (dwCode==HTTP_STATUS_REDIRECT || dwCode==HTTP_STATUS_MOVED) && HTTP_HttpQueryInfoW(lpwhr,HTTP_QUERY_LOCATION,szNewLocation,&dwBufferSize,NULL)) @@ -2988,7 +2988,7 @@ static VOID HTTP_CloseConnection(LPWININETHTTPREQW lpwhr) BOOL HTTP_FinishedReading(LPWININETHTTPREQW lpwhr) { WCHAR szConnectionResponse[20]; - DWORD dwBufferSize = sizeof(szConnectionResponse)/sizeof(szConnectionResponse[0]); + DWORD dwBufferSize = sizeof(szConnectionResponse); TRACE("\n");