From ef5f2638a39feae8a5c883e90084c3cb03a682ad Mon Sep 17 00:00:00 2001 From: Witold Filipczyk Date: Sun, 7 Jan 2007 16:24:46 +0100 Subject: [PATCH] Drop to_read. --- src/protocol/http/http.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/protocol/http/http.c b/src/protocol/http/http.c index 3d116121..a69da1be 100644 --- a/src/protocol/http/http.c +++ b/src/protocol/http/http.c @@ -978,14 +978,12 @@ decompress_data(struct connection *conn, unsigned char *data, int len, do { /* The initial value is used only when state == NORMAL. * Unconditional initialization avoids a GCC warning. */ - int to_read = PIPE_BUF; - if (state == NORMAL) { /* ... we aren't finishing yet. */ int written; written = safe_write(conn->stream_pipes[1], data, - len > to_read ? to_read : len); + len > PIPE_BUF ? PIPE_BUF : len); if (written > 0) { data += written;