From 1d04b14c09ee678a184c0acbd91b532110c02dd9 Mon Sep 17 00:00:00 2001 From: Igor Sysoev Date: Thu, 15 Nov 2007 14:26:36 +0000 Subject: 64-bit time_t compatibility --- src/core/ngx_times.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/core/ngx_times.c') diff --git a/src/core/ngx_times.c b/src/core/ngx_times.c index 551e10258..949e0c6f7 100644 --- a/src/core/ngx_times.c +++ b/src/core/ngx_times.c @@ -205,16 +205,16 @@ ngx_gmtime(time_t t, ngx_tm_t *tp) { ngx_int_t sec, min, hour, mday, mon, year, wday, yday, days; - days = t / 86400; + days = (ngx_int_t) (t / 86400); /* Jaunary 1, 1970 was Thursday */ wday = (4 + days) % 7; t %= 86400; - hour = t / 3600; + hour = (ngx_int_t) (t / 3600); t %= 3600; - min = t / 60; - sec = t % 60; + min = (ngx_int_t) (t / 60); + sec = (ngx_int_t) (t % 60); /* the algorithm based on Gauss's formula */ -- cgit