Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nginx/nginx.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIgor Sysoev <igor@sysoev.ru>2007-05-05 10:07:11 +0400
committerIgor Sysoev <igor@sysoev.ru>2007-05-05 10:07:11 +0400
commitb09c269386d4357246617e1acbb254e0bce3edeb (patch)
treeb63868c5cd778c57a1088f4a5f25ffc8010149fe
parent875893b846a11908de51ed12ebcffb837115fdcd (diff)
style fix: change variable name
-rw-r--r--src/http/ngx_http_write_filter_module.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/http/ngx_http_write_filter_module.c b/src/http/ngx_http_write_filter_module.c
index 2015c43ba..21c1793b0 100644
--- a/src/http/ngx_http_write_filter_module.c
+++ b/src/http/ngx_http_write_filter_module.c
@@ -47,7 +47,7 @@ ngx_module_t ngx_http_write_filter_module = {
ngx_int_t
ngx_http_write_filter(ngx_http_request_t *r, ngx_chain_t *in)
{
- off_t size, sent, to_send;
+ off_t size, sent, limit;
ngx_uint_t last, flush;
ngx_chain_t *cl, *ln, **ll, *chain;
ngx_connection_t *c;
@@ -210,12 +210,12 @@ ngx_http_write_filter(ngx_http_request_t *r, ngx_chain_t *in)
}
if (r->limit_rate) {
- to_send = r->limit_rate * (ngx_time() - r->start_sec + 1) - c->sent;
+ limit = r->limit_rate * (ngx_time() - r->start_sec + 1) - c->sent;
- if (to_send <= 0) {
+ if (limit <= 0) {
c->write->delayed = 1;
ngx_add_timer(c->write,
- (ngx_msec_t) (- to_send * 1000 / r->limit_rate + 1));
+ (ngx_msec_t) (- limit * 1000 / r->limit_rate + 1));
c->buffered |= NGX_HTTP_WRITE_BUFFERED;
@@ -223,15 +223,15 @@ ngx_http_write_filter(ngx_http_request_t *r, ngx_chain_t *in)
}
} else {
- to_send = 0;
+ limit = 0;
}
sent = c->sent;
ngx_log_debug1(NGX_LOG_DEBUG_HTTP, c->log, 0,
- "http write filter to send %O", to_send);
+ "http write filter limit %O", limit);
- chain = c->send_chain(c, r->out, to_send);
+ chain = c->send_chain(c, r->out, limit);
ngx_log_debug1(NGX_LOG_DEBUG_HTTP, c->log, 0,
"http write filter %p", chain);
@@ -241,7 +241,7 @@ ngx_http_write_filter(ngx_http_request_t *r, ngx_chain_t *in)
return NGX_ERROR;
}
- if (to_send) {
+ if (limit) {
sent = c->sent - sent;
c->write->delayed = 1;
ngx_add_timer(c->write, (ngx_msec_t) (sent * 1000 / r->limit_rate + 1));