OSDN Git Service

* localtime.cc (time2): Take a stab at fixing a compiler warning.
authorcgf <cgf>
Sun, 14 Jun 2009 05:49:01 +0000 (05:49 +0000)
committercgf <cgf>
Sun, 14 Jun 2009 05:49:01 +0000 (05:49 +0000)
winsup/cygwin/ChangeLog
winsup/cygwin/localtime.cc

index da662b0..b0b8791 100644 (file)
@@ -1,5 +1,9 @@
 2009-06-14  Christopher Faylor  <me+cygwin@cgf.cx>
 
+       * localtime.cc (time2): Take a stab at fixing a compiler warning.
+
+2009-06-14  Christopher Faylor  <me+cygwin@cgf.cx>
+
        * fhandler.cc (fhandler_base::wait_overlapped): Honor nonblocking flag
        for writes.  Don't reset event handle when we see a ERROR_IO_PENDING.
 
index c655961..738f178 100644 (file)
@@ -2006,7 +2006,7 @@ time2(struct tm *tmp, void (*funcp) P((const time_t*, long, struct tm*)),
        t = time2sub(&tmp2, funcp, offset, okayp, true);
        if (*okayp)
          {
-           if (t + 3600 < t)   /* Sanity check */
+           if (tmp2.tm_sec + 3600 < t) /* Sanity check */
              return WRONG;
            return t + 3600;
          }