Mercurial > hg > nginx
diff src/http/modules/ngx_http_upstream_keepalive_module.c @ 5864:39befd3c0d84
Upstream keepalive: reset c->sent on cached connections.
The c->sent is reset to 0 on each request by server-side http code,
so do the same on client side. This allows to count number of bytes
sent in a particular request.
author | Maxim Dounin <mdounin@mdounin.ru> |
---|---|
date | Mon, 29 Sep 2014 22:27:45 +0400 |
parents | 3e5b630e0ec9 |
children | 4d8936b1fc32 |
line wrap: on
line diff
--- a/src/http/modules/ngx_http_upstream_keepalive_module.c Wed Sep 24 21:55:19 2014 +0400 +++ b/src/http/modules/ngx_http_upstream_keepalive_module.c Mon Sep 29 22:27:45 2014 +0400 @@ -248,6 +248,7 @@ "get keepalive peer: using connection %p", c); c->idle = 0; + c->sent = 0; c->log = pc->log; c->read->log = pc->log; c->write->log = pc->log;