diff --git a/patches/nginx-1.2.7-upstream_truncation.patch b/patches/nginx-1.2.7-upstream_truncation.patch index 5cbee2d..c8cddf4 100644 --- a/patches/nginx-1.2.7-upstream_truncation.patch +++ b/patches/nginx-1.2.7-upstream_truncation.patch @@ -76,7 +76,7 @@ diff --exclude '*~' --exclude '*.swp' -urp nginx-1.2.7/src/http/modules/ngx_http { diff --exclude '*~' --exclude '*.swp' -urp nginx-1.2.7/src/http/ngx_http_upstream.c nginx-1.2.7-patched/src/http/ngx_http_upstream.c --- nginx-1.2.7/src/http/ngx_http_upstream.c 2013-02-11 06:39:49.000000000 -0800 -+++ nginx-1.2.7-patched/src/http/ngx_http_upstream.c 2013-04-06 17:16:54.444520038 -0700 ++++ nginx-1.2.7-patched/src/http/ngx_http_upstream.c 2013-04-08 16:37:48.326752696 -0700 @@ -2399,7 +2399,7 @@ ngx_http_upstream_process_non_buffered_u if (c->read->timedout) { @@ -95,7 +95,7 @@ diff --exclude '*~' --exclude '*.swp' -urp nginx-1.2.7/src/http/ngx_http_upstrea + || (upstream->read->eof + && u->length == -1 + && u->pipe -+ && u->pipe->length == -1)) ++ && u->pipe->length <= 0)) { ngx_http_upstream_finalize_request(r, u, 0); return; @@ -115,7 +115,7 @@ diff --exclude '*~' --exclude '*.swp' -urp nginx-1.2.7/src/http/ngx_http_upstrea - if (p->upstream_done || p->upstream_eof || p->upstream_error) { + if (p->upstream_done -+ || (p->upstream_eof && u->length == -1 && p->length == -1)) ++ || (p->upstream_eof && u->length == -1 && p->length <= 0)) + { ngx_log_debug1(NGX_LOG_DEBUG_HTTP, r->connection->log, 0, "http upstream exit: %p", p->out); diff --git a/util/ver b/util/ver index f5a5a97..839df3d 100755 --- a/util/ver +++ b/util/ver @@ -2,7 +2,7 @@ #main_ver=1.3.11 main_ver=1.2.7 -minor_ver=5rc2 +minor_ver=5rc4 version=$main_ver.$minor_ver echo $version