diff src/http/ngx_http_upstream.c @ 314:d5ec0be9c835 NGINX_0_6_1

nginx 0.6.1 *) Bugfix: in SSI parsing. *) Bugfix: if remote SSI subrequest was used, then posterior local file subrequest might transferred to client in wrong order. *) Bugfix: large SSI inclusions buffered in temporary files were truncated. *) Bugfix: the perl $$ variable value in ngx_http_perl_module was equal to the master process identification number.
author Igor Sysoev <http://sysoev.ru>
date Sun, 17 Jun 2007 00:00:00 +0400
parents 95d92ec39071
children fc223117327f
line wrap: on
line diff
--- a/src/http/ngx_http_upstream.c
+++ b/src/http/ngx_http_upstream.c
@@ -2157,8 +2157,17 @@ ngx_http_upstream_finalize_request(ngx_h
 
     r->connection->log->action = "sending to client";
 
-    if (rc == 0 && r == r->main && !r->post_action) {
-        rc = ngx_http_send_special(r, NGX_HTTP_LAST);
+    if (rc == 0) {
+        if (r == r->main) {
+            if (!r->post_action) {
+                rc = ngx_http_send_special(r, NGX_HTTP_LAST);
+            }
+
+        } else {
+            if (r->out) {
+                rc = NGX_AGAIN;
+            }
+        }
     }
 
     ngx_http_finalize_request(r, rc);