Skip to content

Commit

Permalink
Merge branch 'splitice-master'
Browse files Browse the repository at this point in the history
  • Loading branch information
Lax committed Aug 15, 2015
2 parents 8407802 + 964189c commit 21e7872
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/ngx_http_accounting_worker_process.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
#include <ngx_core.h>
#include <ngx_http.h>
#include <ngx_http_upstream.h>
#include <nginx.h>

#include <syslog.h>

Expand Down Expand Up @@ -108,7 +109,11 @@ ngx_http_accounting_handler(ngx_http_request_t *r)
state = r->upstream_states->elts;
if (state[0].status) {
// not even checking the status here...
upstream_req_latency_ms = (state[0].response_sec * 1000 + state[0].response_msec);
#if (nginx_version < 1009000)
upstream_req_latency_ms = (state[0].response_sec * 1000 + state[0].response_msec);
#else
upstream_req_latency_ms = state[0].response_time;
#endif
}
}
// TODO: key should be cached to save CPU time
Expand Down

0 comments on commit 21e7872

Please sign in to comment.