Hans Leidekker : winhttp: Reset content length when a redirect creates a new connection.

Alexandre Julliard julliard at winehq.org
Fri Oct 20 07:19:57 CDT 2017


Module: wine
Branch: stable
Commit: 6d4d378b5d2f902d70468c9e7dfb71eff95d73b7
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=6d4d378b5d2f902d70468c9e7dfb71eff95d73b7

Author: Hans Leidekker <hans at codeweavers.com>
Date:   Thu Jun 22 14:16:58 2017 +0200

winhttp: Reset content length when a redirect creates a new connection.

Signed-off-by: Hans Leidekker <hans at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
(cherry picked from commit f2bb2064bfdf0e7b369f22c34d680dec6c12493c)
Signed-off-by: Michael Stefaniuc <mstefani at winehq.org>

---

 dlls/winhttp/request.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/winhttp/request.c b/dlls/winhttp/request.c
index fc04794..97fd1de 100644
--- a/dlls/winhttp/request.c
+++ b/dlls/winhttp/request.c
@@ -2349,9 +2349,9 @@ static BOOL handle_redirect( request_t *request, DWORD status )
 
             netconn_close( &request->netconn );
             if (!(ret = netconn_init( &request->netconn ))) goto end;
+            request->content_length = request->content_read = 0;
             request->read_pos = request->read_size = 0;
-            request->read_chunked = FALSE;
-            request->read_chunked_eof = FALSE;
+            request->read_chunked = request->read_chunked_eof = FALSE;
         }
         else heap_free( hostname );
 




More information about the wine-cvs mailing list