Fix two problems with chunked gzipped HTTP replies.
* receiveEnd is set in a different place in case of chunked transfers, which would cause the decompressor to never be flushed. * In the case of chunked transfers, we call Flush() without any input data (to flush only whatever is remaining in the decompression buffer). This causes ZLib to return Z_BUF_ERROR which is translated to B_BUFFER_OVERFLOW. This is a non-fatal error and is expected behavior in that case. Don't handle this as an error, and do use the extracted data. Fixes various cases of missing the last chunk of a page (pastie.org, Google search results, and more).
This commit is contained in:
@@ -68,6 +68,7 @@ private:
|
||||
|
||||
void _SendRequest();
|
||||
void _SendHeaders();
|
||||
void _SendPostData();
|
||||
|
||||
status_t _GetLine(BString& destString);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user