comparison src/http/ngx_http_postpone_filter_module.c @ 668:9fbf3ad94cbf NGINX_1_1_18

nginx 1.1.18 *) Change: keepalive connections are no longer disabled for Safari by default. *) Feature: the $connection_requests variable. *) Feature: $tcpinfo_rtt, $tcpinfo_rttvar, $tcpinfo_snd_cwnd and $tcpinfo_rcv_space variables. *) Feature: the "worker_cpu_affinity" directive now works on FreeBSD. *) Feature: the "xslt_param" and "xslt_string_param" directives. Thanks to Samuel Behan. *) Bugfix: in configure tests. Thanks to Piotr Sikora. *) Bugfix: in the ngx_http_xslt_filter_module. *) Bugfix: nginx could not be built on Debian GNU/Hurd.
author Igor Sysoev <http://sysoev.ru>
date Wed, 28 Mar 2012 00:00:00 +0400
parents d0f7a625f27c
children
comparison
equal deleted inserted replaced
667:e0eabdb2bad1 668:9fbf3ad94cbf
44 NULL, /* exit master */ 44 NULL, /* exit master */
45 NGX_MODULE_V1_PADDING 45 NGX_MODULE_V1_PADDING
46 }; 46 };
47 47
48 48
49 static ngx_http_output_body_filter_pt ngx_http_next_filter; 49 static ngx_http_output_body_filter_pt ngx_http_next_body_filter;
50 50
51 51
52 static ngx_int_t 52 static ngx_int_t
53 ngx_http_postpone_filter(ngx_http_request_t *r, ngx_chain_t *in) 53 ngx_http_postpone_filter(ngx_http_request_t *r, ngx_chain_t *in)
54 { 54 {
78 } 78 }
79 79
80 if (r->postponed == NULL) { 80 if (r->postponed == NULL) {
81 81
82 if (in || c->buffered) { 82 if (in || c->buffered) {
83 return ngx_http_next_filter(r->main, in); 83 return ngx_http_next_body_filter(r->main, in);
84 } 84 }
85 85
86 return NGX_OK; 86 return NGX_OK;
87 } 87 }
88 88
114 } else { 114 } else {
115 ngx_log_debug2(NGX_LOG_DEBUG_HTTP, c->log, 0, 115 ngx_log_debug2(NGX_LOG_DEBUG_HTTP, c->log, 0,
116 "http postpone filter output \"%V?%V\"", 116 "http postpone filter output \"%V?%V\"",
117 &r->uri, &r->args); 117 &r->uri, &r->args);
118 118
119 if (ngx_http_next_filter(r->main, pr->out) == NGX_ERROR) { 119 if (ngx_http_next_body_filter(r->main, pr->out) == NGX_ERROR) {
120 return NGX_ERROR; 120 return NGX_ERROR;
121 } 121 }
122 } 122 }
123 123
124 r->postponed = pr->next; 124 r->postponed = pr->next;
169 169
170 170
171 static ngx_int_t 171 static ngx_int_t
172 ngx_http_postpone_filter_init(ngx_conf_t *cf) 172 ngx_http_postpone_filter_init(ngx_conf_t *cf)
173 { 173 {
174 ngx_http_next_filter = ngx_http_top_body_filter; 174 ngx_http_next_body_filter = ngx_http_top_body_filter;
175 ngx_http_top_body_filter = ngx_http_postpone_filter; 175 ngx_http_top_body_filter = ngx_http_postpone_filter;
176 176
177 return NGX_OK; 177 return NGX_OK;
178 } 178 }