Module: wine Branch: master Commit: 3b052877e46c7ae7cbedfd8f71ea58b691504dc8 URL: https://source.winehq.org/git/wine.git/?a=commit;h=3b052877e46c7ae7cbedfd8f7...
Author: Dmitry Timoshkov dmitry@baikal.ru Date: Thu Jun 3 17:01:06 2021 +0300
wininet: Reset buffer size before each call to HTTP_HttpQueryInfoW.
Otherwise when headers contain multiple entries like
WWW-Authenticate: Negotiate WWW-Authenticate: Basic realm="SAMPLE.COM"
then 2nd query fails because buffer size is shorter than the header value.
Signed-off-by: Dmitry Timoshkov dmitry@baikal.ru Signed-off-by: Alexandre Julliard julliard@winehq.org
---
dlls/wininet/http.c | 4 ++++ 1 file changed, 4 insertions(+)
diff --git a/dlls/wininet/http.c b/dlls/wininet/http.c index c770c312ba9..eedb210cd23 100644 --- a/dlls/wininet/http.c +++ b/dlls/wininet/http.c @@ -5125,6 +5125,8 @@ static DWORD HTTP_HttpSendRequestW(http_request_t *request, LPCWSTR lpszHeaders, loop_next = TRUE; break; } + + dwBufferSize = 2048; } heap_free( host );
@@ -5153,6 +5155,8 @@ static DWORD HTTP_HttpSendRequestW(http_request_t *request, LPCWSTR lpszHeaders, loop_next = TRUE; break; } + + dwBufferSize = 2048; }
if(!loop_next) {