summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHarry Sintonen <sintonen@iki.fi>2018-07-27 01:04:29 +0300
committerDaniel Stenberg <daniel@haxx.se>2018-07-31 17:10:22 +0200
commit1836d59ed8a3f052a3fa6aa676c10721d8b57492 (patch)
treef980fd207f92add10674ef7b2a3a76be9b779d82
parente78f2cfe56c39a6c32191c207aae683de0e9a042 (diff)
downloadcurl-1836d59ed8a3f052a3fa6aa676c10721d8b57492.tar.gz
HTTP: Don't attempt to needlessly decompress redirect body
This change fixes a regression where redirect body would needlessly be decompressed even though it was to be ignored anyway. As it happens this causes secondary issues since there appears to be a bug in apache2 that it in certain conditions generates a corrupt zlib response. The regression was created by commit: dbcced8e32b50c068ac297106f0502ee200a1ebd Discovered-by: Harry Sintonen Closes #2798
-rw-r--r--lib/transfer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/transfer.c b/lib/transfer.c
index 435d3e1ec..43f567c4f 100644
--- a/lib/transfer.c
+++ b/lib/transfer.c
@@ -797,7 +797,7 @@ static CURLcode readwrite_data(struct Curl_easy *data,
nread);
}
}
- else
+ else if(!k->ignorebody)
result = Curl_unencode_write(conn, k->writer_stack, k->str, nread);
}
k->badheader = HEADER_NORMAL; /* taken care of now */