mirror of
https://github.com/alibaba/tengine.git
synced 2026-03-13 07:51:16 +08:00
Bugfix: r->limit_rate does't work if limit_rate_set variable is not set
nginx-patch: https://hg.nginx.org/nginx/rev/c19ca381b2e6\?revcount\=480
This commit is contained in:
@@ -1131,6 +1131,7 @@ ngx_http_tfs_send_response(ngx_http_request_t *r, ngx_http_tfs_t *t)
|
||||
r->write_event_handler = ngx_http_tfs_process_non_buffered_downstream;
|
||||
|
||||
r->limit_rate = 0;
|
||||
r->limit_rate_set = 1;
|
||||
|
||||
if (clcf->tcp_nodelay && c->tcp_nodelay == NGX_TCP_NODELAY_UNSET) {
|
||||
ngx_log_debug0(NGX_LOG_DEBUG_HTTP, c->log, 0, "tcp_nodelay");
|
||||
|
||||
@@ -62,6 +62,7 @@ ngx_http_multi_upstream_send_response(ngx_http_request_t *r, ngx_http_upstream_t
|
||||
ngx_http_upstream_process_non_buffered_downstream;
|
||||
|
||||
r->limit_rate = 0;
|
||||
r->limit_rate_set = 1;
|
||||
|
||||
if (u->input_filter_init(u->input_filter_ctx) == NGX_ERROR) {
|
||||
ngx_http_upstream_finalize_request(r, u, NGX_ERROR);
|
||||
|
||||
Reference in New Issue
Block a user