nginx-1.2.7-upstream_truncation.patch: worked around an issue in ngx_event_pipe_copy_input_filter because it does not set p->upstream_done when p->length <= 0 like ngx_http_proxy_copy_filter.
This commit is contained in:
parent
13efb24106
commit
49d9d9b778
|
@ -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
|
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/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
|
@@ -2399,7 +2399,7 @@ ngx_http_upstream_process_non_buffered_u
|
||||||
|
|
||||||
if (c->read->timedout) {
|
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
|
+ || (upstream->read->eof
|
||||||
+ && u->length == -1
|
+ && u->length == -1
|
||||||
+ && u->pipe
|
+ && u->pipe
|
||||||
+ && u->pipe->length == -1))
|
+ && u->pipe->length <= 0))
|
||||||
{
|
{
|
||||||
ngx_http_upstream_finalize_request(r, u, 0);
|
ngx_http_upstream_finalize_request(r, u, 0);
|
||||||
return;
|
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 || p->upstream_error) {
|
||||||
+ if (p->upstream_done
|
+ 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,
|
ngx_log_debug1(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
|
||||||
"http upstream exit: %p", p->out);
|
"http upstream exit: %p", p->out);
|
||||||
|
|
Loading…
Reference in New Issue