Commit 0a7e6caa authored by Martin Blix Grydeland's avatar Martin Blix Grydeland

Fix duplicate Content-Length headers with pass and stream

Fixes: #1272

Patch by: ehocdet
parent 88d785b3
......@@ -352,9 +352,11 @@ RES_StreamStart(struct sess *sp)
http_Unset(sp->wrk->resp, H_Content_Encoding);
if (!(sp->wrk->res_mode & RES_CHUNKED) &&
sp->wrk->h_content_length != NULL)
sp->wrk->h_content_length != NULL) {
http_Unset(sp->wrk->resp, H_Content_Length);
http_PrintfHeader(sp->wrk, sp->fd, sp->wrk->resp,
"Content-Length: %s", sp->wrk->h_content_length);
}
sp->wrk->acct_tmp.hdrbytes +=
http_Write(sp->wrk, sp->wrk->resp, 1);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment