[git commit master 1/1] httpd: don't send error messages with gzip encoding

Denys Vlasenko vda.linux at googlemail.com
Sun Mar 27 21:26:33 UTC 2011

commit: http://git.busybox.net/busybox/commit/?id=95755181b828cccaa833d7b8d1d47174b7b360b7
branch: http://git.busybox.net/busybox/commit/?id=refs/heads/master

If CONFIG_FEATURE_HTTPD_GZIP is enabled and request contained
'Accept-Encoding: gzip', then errors were sent with 'Content-Encoding: gzip'
even though they aren't.

Fix it by clearing content_gzip before sending the headers.

Signed-off-by: Peter Korsgaard <jacmet at sunsite.dk>
Signed-off-by: Denys Vlasenko <vda.linux at googlemail.com>
 networking/httpd.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/networking/httpd.c b/networking/httpd.c
index b8113a8..9c1aa2a 100644
--- a/networking/httpd.c
+++ b/networking/httpd.c
@@ -1065,6 +1065,7 @@ static void send_headers(int responseNum)
 static void send_headers_and_exit(int responseNum) NORETURN;
 static void send_headers_and_exit(int responseNum)
+	IF_FEATURE_HTTPD_GZIP(content_gzip = 0;)

More information about the busybox-cvs mailing list