apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From traw...@apache.org
Subject svn commit: r1372090 - in /apr/apr/branches/0.9.x: ./ CHANGES time/win32/time.c
Date Sun, 12 Aug 2012 13:22:19 GMT
Author: trawick
Date: Sun Aug 12 13:22:19 2012
New Revision: 1372090

URL: http://svn.apache.org/viewvc?rev=1372090&view=rev
Log:
merge r1372022 from trunk:

apr_time_exp_*() on Windows: Fix error in the tm_yday field of
apr_time_exp_t for times within leap years.

PR: 53175

Modified:
    apr/apr/branches/0.9.x/   (props changed)
    apr/apr/branches/0.9.x/CHANGES
    apr/apr/branches/0.9.x/time/win32/time.c

Propchange: apr/apr/branches/0.9.x/
------------------------------------------------------------------------------
  Merged /apr/apr/trunk:r1372022

Modified: apr/apr/branches/0.9.x/CHANGES
URL: http://svn.apache.org/viewvc/apr/apr/branches/0.9.x/CHANGES?rev=1372090&r1=1372089&r2=1372090&view=diff
==============================================================================
--- apr/apr/branches/0.9.x/CHANGES [utf-8] (original)
+++ apr/apr/branches/0.9.x/CHANGES [utf-8] Sun Aug 12 13:22:19 2012
@@ -1,6 +1,10 @@
                                                      -*- coding: utf-8 -*-
 Changes with APR 0.9.21
 
+  *) apr_time_exp_*() on Windows: Fix error in the tm_yday field of
+     apr_time_exp_t for times within leap years.  PR 53175.
+     [Jeff Trawick]
+
   *) Improve platform detection by updating config.guess and config.sub.
      [Rainer Jung]
 

Modified: apr/apr/branches/0.9.x/time/win32/time.c
URL: http://svn.apache.org/viewvc/apr/apr/branches/0.9.x/time/win32/time.c?rev=1372090&r1=1372089&r2=1372090&view=diff
==============================================================================
--- apr/apr/branches/0.9.x/time/win32/time.c (original)
+++ apr/apr/branches/0.9.x/time/win32/time.c Sun Aug 12 13:22:19 2012
@@ -32,7 +32,7 @@
 /* Leap year is any year divisible by four, but not by 100 unless also
  * divisible by 400
  */
-#define IsLeapYear(y) ((!(y % 4)) ? (((!(y % 400)) && (y % 100)) ? 1 : 0) : 0)
+#define IsLeapYear(y) ((!(y % 4)) ? (((y % 400) && !(y % 100)) ? 0 : 1) : 0)
 
 static DWORD get_local_timezone(TIME_ZONE_INFORMATION **tzresult)
 {



Mime
View raw message