aboutsummaryrefslogtreecommitdiff
path: root/src/http/modules/ngx_http_fastcgi_module.c
diff options
context:
space:
mode:
authorRoman Arutyunyan <arut@nginx.com>2014-10-14 18:32:01 +0400
committerRoman Arutyunyan <arut@nginx.com>2014-10-14 18:32:01 +0400
commit2244a5e9cf40d271ddf31f083acd694b5d9f13b4 (patch)
tree970d41c3114c3d10ebccaa30dbbdd687752b5c36 /src/http/modules/ngx_http_fastcgi_module.c
parent8ae7751878b60f2822e530cd8b5d26b59ea9236a (diff)
downloadnginx-2244a5e9cf40d271ddf31f083acd694b5d9f13b4.tar.gz
nginx-2244a5e9cf40d271ddf31f083acd694b5d9f13b4.zip
Upstream: proxy_force_ranges and friends.
The directives enable byte ranges for both cached and uncached responses regardless of backend headers.
Diffstat (limited to 'src/http/modules/ngx_http_fastcgi_module.c')
-rw-r--r--src/http/modules/ngx_http_fastcgi_module.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/http/modules/ngx_http_fastcgi_module.c b/src/http/modules/ngx_http_fastcgi_module.c
index a49c93ca2..49513295d 100644
--- a/src/http/modules/ngx_http_fastcgi_module.c
+++ b/src/http/modules/ngx_http_fastcgi_module.c
@@ -326,6 +326,13 @@ static ngx_command_t ngx_http_fastcgi_commands[] = {
offsetof(ngx_http_fastcgi_loc_conf_t, upstream.busy_buffers_size_conf),
NULL },
+ { ngx_string("fastcgi_force_ranges"),
+ NGX_HTTP_MAIN_CONF|NGX_HTTP_SRV_CONF|NGX_HTTP_LOC_CONF|NGX_CONF_FLAG,
+ ngx_conf_set_flag_slot,
+ NGX_HTTP_LOC_CONF_OFFSET,
+ offsetof(ngx_http_fastcgi_loc_conf_t, upstream.force_ranges),
+ NULL },
+
#if (NGX_HTTP_CACHE)
{ ngx_string("fastcgi_cache"),
@@ -2332,6 +2339,7 @@ ngx_http_fastcgi_create_loc_conf(ngx_conf_t *cf)
conf->upstream.next_upstream_tries = NGX_CONF_UNSET_UINT;
conf->upstream.buffering = NGX_CONF_UNSET;
conf->upstream.ignore_client_abort = NGX_CONF_UNSET;
+ conf->upstream.force_ranges = NGX_CONF_UNSET;
conf->upstream.local = NGX_CONF_UNSET_PTR;
@@ -2413,6 +2421,9 @@ ngx_http_fastcgi_merge_loc_conf(ngx_conf_t *cf, void *parent, void *child)
ngx_conf_merge_value(conf->upstream.ignore_client_abort,
prev->upstream.ignore_client_abort, 0);
+ ngx_conf_merge_value(conf->upstream.force_ranges,
+ prev->upstream.force_ranges, 0);
+
ngx_conf_merge_ptr_value(conf->upstream.local,
prev->upstream.local, NULL);