fix(compress): do not compress 206 Partial Content responses (#5020)
Before adoption: this commit came in with the history the project adopted, so no landing records it.
compress() never looked at the response status, so a 206 was gzipped while its Content-Range header still described the uncompressed byte range, and the Content-Length matching the partial body was dropped. Range clients reassembling parts from such responses end up with corrupted data. Skip compression when the status is 206. Reported as the second issue in #5010.
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Diff stats
2 files+15 added−0 removed
- tests:+14 added−0 removed
- other:+1 added−0 removed