diff options
author | Igor Sysoev <igor@sysoev.ru> | 2010-05-12 17:12:31 +0400 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2010-05-12 17:12:31 +0400 |
commit | 503b9716c5ebf3e8870b5560220341b5ad480734 (patch) | |
tree | 6168deaa98b80ad4c476271c89c01fa7ba8d4308 /src/core/ngx_string.c | |
parent | ab4c0d36284d822cc8edd71d24520f806ce971e7 (diff) |
use double in %f format to allow %.15f precision
Diffstat (limited to 'src/core/ngx_string.c')
-rw-r--r-- | src/core/ngx_string.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/core/ngx_string.c b/src/core/ngx_string.c index a1aeb4764..ce1fad65c 100644 --- a/src/core/ngx_string.c +++ b/src/core/ngx_string.c @@ -75,7 +75,7 @@ ngx_pstrdup(ngx_pool_t *pool, ngx_str_t *src) * %[0][width][u][x|X]D int32_t/uint32_t * %[0][width][u][x|X]L int64_t/uint64_t * %[0][width|m][u][x|X]A ngx_atomic_int_t/ngx_atomic_uint_t - * %[0][width][.width]f float + * %[0][width][.width]f double, max valid number fits to %18.15f * %P ngx_pid_t * %M ngx_msec_t * %r rlim_t @@ -143,7 +143,7 @@ ngx_vslprintf(u_char *buf, u_char *last, const char *fmt, va_list args) { u_char *p, zero; int d; - float f, scale; + double f, scale; size_t len, slen; int64_t i64; uint64_t ui64; @@ -359,7 +359,7 @@ ngx_vslprintf(u_char *buf, u_char *last, const char *fmt, va_list args) break; case 'f': - f = (float) va_arg(args, double); + f = va_arg(args, double); if (f < 0) { *buf++ = '-'; |