From 7453b032799019e9eb505395158e92dcdb6de070 Mon Sep 17 00:00:00 2001 From: Witold Filipczyk Date: Mon, 1 Sep 2014 12:50:23 +0200 Subject: [PATCH] deflate switched on again. askubuntu.com uses deflate compression. --- src/encoding/deflate.c | 4 +--- src/protocol/http/http.c | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/encoding/deflate.c b/src/encoding/deflate.c index a62e123d1..6a9b4589c 100644 --- a/src/encoding/deflate.c +++ b/src/encoding/deflate.c @@ -73,14 +73,12 @@ deflate_open(int window_size, struct stream_encoded *stream, int fd) return 0; } -#if 0 static int deflate_raw_open(struct stream_encoded *stream, int fd) { /* raw DEFLATE with neither zlib nor gzip header */ return deflate_open(-MAX_WBITS, stream, fd); } -#endif static int deflate_gzip_open(struct stream_encoded *stream, int fd) @@ -256,7 +254,7 @@ static const unsigned char *const deflate_extensions[] = { NULL }; const struct decoding_backend deflate_decoding_backend = { "deflate", deflate_extensions, - deflate_gzip_open, + deflate_raw_open, deflate_read, deflate_raw_decode_buffer, deflate_close, diff --git a/src/protocol/http/http.c b/src/protocol/http/http.c index d7015b899..6f962cc7b 100644 --- a/src/protocol/http/http.c +++ b/src/protocol/http/http.c @@ -600,7 +600,7 @@ accept_encoding_header(struct string *header) #ifdef CONFIG_GZIP if (comma) add_to_string(header, ", "); - add_to_string(header, "gzip"); + add_to_string(header, "deflate, gzip"); comma = 1; #endif