aboutsummaryrefslogtreecommitdiff
path: root/src/http/modules/ngx_http_log_module.c
diff options
context:
space:
mode:
authorMaxim Dounin <mdounin@mdounin.ru>2013-09-04 20:48:30 +0400
committerMaxim Dounin <mdounin@mdounin.ru>2013-09-04 20:48:30 +0400
commit8e69bbf44e18a08603a20bd81a7129e834e9b327 (patch)
tree025284e4563e2e3c8d3095b3865593291d7ad5b6 /src/http/modules/ngx_http_log_module.c
parentb5656b31f14dd1dd126e9ae10fd8d0b932904388 (diff)
downloadnginx-8e69bbf44e18a08603a20bd81a7129e834e9b327.tar.gz
nginx-8e69bbf44e18a08603a20bd81a7129e834e9b327.zip
Win32: $request_time fixed.
On win32, time_t is 64 bits wide by default, and passing an ngx_msec_int_t argument for %T format specifier doesn't work. This doesn't manifest itself on other platforms as time_t and ngx_msec_int_t are usually of the same size.
Diffstat (limited to 'src/http/modules/ngx_http_log_module.c')
-rw-r--r--src/http/modules/ngx_http_log_module.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/http/modules/ngx_http_log_module.c b/src/http/modules/ngx_http_log_module.c
index aa6a3fcee..7eb29b38a 100644
--- a/src/http/modules/ngx_http_log_module.c
+++ b/src/http/modules/ngx_http_log_module.c
@@ -780,7 +780,7 @@ ngx_http_log_request_time(ngx_http_request_t *r, u_char *buf,
((tp->sec - r->start_sec) * 1000 + (tp->msec - r->start_msec));
ms = ngx_max(ms, 0);
- return ngx_sprintf(buf, "%T.%03M", ms / 1000, ms % 1000);
+ return ngx_sprintf(buf, "%T.%03M", (time_t) ms / 1000, ms % 1000);
}