aboutsummaryrefslogtreecommitdiff
path: root/src/http/modules/ngx_http_fastcgi_module.c
diff options
context:
space:
mode:
authorRoman Arutyunyan <arut@nginx.com>2018-02-28 16:56:58 +0300
committerRoman Arutyunyan <arut@nginx.com>2018-02-28 16:56:58 +0300
commit7c5c15a25d22b05f1baabfb14395a7924fe4fd8c (patch)
treebacddae8536e0747fa68e66d3e913d4aef9f93b6 /src/http/modules/ngx_http_fastcgi_module.c
parent2d9db482aa92194a2258334545908d620b6dd214 (diff)
downloadnginx-7c5c15a25d22b05f1baabfb14395a7924fe4fd8c.tar.gz
nginx-7c5c15a25d22b05f1baabfb14395a7924fe4fd8c.zip
Generic subrequests in memory.
Previously, only the upstream response body could be accessed with the NGX_HTTP_SUBREQUEST_IN_MEMORY feature. Now any response body from a subrequest can be saved in a memory buffer. It is available as a single buffer in r->out and the buffer size is configured by the subrequest_output_buffer_size directive. Upstream, proxy and fastcgi code used to handle the old-style feature is removed.
Diffstat (limited to 'src/http/modules/ngx_http_fastcgi_module.c')
-rw-r--r--src/http/modules/ngx_http_fastcgi_module.c30
1 files changed, 0 insertions, 30 deletions
diff --git a/src/http/modules/ngx_http_fastcgi_module.c b/src/http/modules/ngx_http_fastcgi_module.c
index b4bb1d0a5..c3f5c4a41 100644
--- a/src/http/modules/ngx_http_fastcgi_module.c
+++ b/src/http/modules/ngx_http_fastcgi_module.c
@@ -2512,36 +2512,6 @@ ngx_http_fastcgi_non_buffered_filter(void *data, ssize_t bytes)
break;
}
- /* provide continuous buffer for subrequests in memory */
-
- if (r->subrequest_in_memory) {
-
- cl = u->out_bufs;
-
- if (cl) {
- buf->pos = cl->buf->pos;
- }
-
- buf->last = buf->pos;
-
- for (cl = u->out_bufs; cl; cl = cl->next) {
- ngx_log_debug3(NGX_LOG_DEBUG_HTTP, r->connection->log, 0,
- "http fastcgi in memory %p-%p %O",
- cl->buf->pos, cl->buf->last, ngx_buf_size(cl->buf));
-
- if (buf->last == cl->buf->pos) {
- buf->last = cl->buf->last;
- continue;
- }
-
- buf->last = ngx_movemem(buf->last, cl->buf->pos,
- cl->buf->last - cl->buf->pos);
-
- cl->buf->pos = buf->last - (cl->buf->last - cl->buf->pos);
- cl->buf->last = buf->last;
- }
- }
-
return NGX_OK;
}