While parsing a chunked response with the curl HTTP transport adapter, there was an issue for parsing the last chunk.
As soon as the end of chunk data was found ("0") the adapter was returning and setting the session state as if the transfer was completed.
However, the HTTP RFC for chunked data (https://tools.ietf.org/html/rfc7230#section-4.1) defines that there is a CRLF after the last chunk info.
By not reading the last CRLF from the response, and if the connection was re-used right after reading the last chunk made the next request to get the `CRLF` as the first part for the response, making the parser crash.
The fix in this PR makes sure that when the last chunk is found and parsed, the CRLF is also parsed from the response to make sure that the response data transfer has completed
fixes: #1396
|
||
|---|---|---|
| .. | ||
| azure-core | ||
| performance-stress | ||
| ci.yml | ||