From cc3000739e8f1a42dd26c354595bf5ead015d55c Mon Sep 17 00:00:00 2001 From: Sascha Wildner Date: Sat, 6 Jun 2009 15:08:38 +0200 Subject: [PATCH] localtime(3): Silence the last i386 warning in libc. Taken-from: FreeBSD --- lib/libc/stdtime/localtime.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/libc/stdtime/localtime.c b/lib/libc/stdtime/localtime.c index 88cfa5428d..85efeec09b 100644 --- a/lib/libc/stdtime/localtime.c +++ b/lib/libc/stdtime/localtime.c @@ -308,10 +308,13 @@ settzname(void) static int differ_by_repeat(const time_t t1, const time_t t0) { + int_fast64_t _t0 = t0; + int_fast64_t _t1 = t1; + if (TYPE_INTEGRAL(time_t) && TYPE_BIT(time_t) - TYPE_SIGNED(time_t) < SECSPERREPEAT_BITS) return 0; - return t1 - t0 == SECSPERREPEAT; + return _t1 - _t0 == SECSPERREPEAT; } static int -- 2.11.4.GIT