Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/lib/libc/time Suppress a warning if time_t is __int64_t



details:   https://anonhg.NetBSD.org/src/rev/11ee2eb4e8e1
branches:  trunk
changeset: 750022:11ee2eb4e8e1
user:      matt <matt%NetBSD.org@localhost>
date:      Mon Dec 14 05:51:56 2009 +0000

description:
Suppress a warning if time_t is __int64_t

diffstat:

 lib/libc/time/strptime.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r e93a8f5c982b -r 11ee2eb4e8e1 lib/libc/time/strptime.c
--- a/lib/libc/time/strptime.c  Mon Dec 14 05:47:30 2009 +0000
+++ b/lib/libc/time/strptime.c  Mon Dec 14 05:51:56 2009 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: strptime.c,v 1.33 2009/05/24 02:25:43 ginsbach Exp $   */
+/*     $NetBSD: strptime.c,v 1.34 2009/12/14 05:51:56 matt Exp $       */
 
 /*-
  * Copyright (c) 1997, 1998, 2005, 2008 The NetBSD Foundation, Inc.
@@ -31,7 +31,7 @@
 
 #include <sys/cdefs.h>
 #if defined(LIBC_SCCS) && !defined(lint)
-__RCSID("$NetBSD: strptime.c,v 1.33 2009/05/24 02:25:43 ginsbach Exp $");
+__RCSID("$NetBSD: strptime.c,v 1.34 2009/12/14 05:51:56 matt Exp $");
 #endif
 
 #include "namespace.h"
@@ -267,7 +267,7 @@
                                        sse *= 10;
                                        sse += *bp++ - '0';
                                        rulim /= 10;
-                               } while ((sse * 10 <= TIME_MAX) &&
+                               } while (((uint64_t)(sse * 10) <= TIME_MAX) &&
                                         rulim && *bp >= '0' && *bp <= '9');
 
                                if (sse < 0 || (uint64_t)sse > TIME_MAX) {



Home | Main Index | Thread Index | Old Index