apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From traw...@apache.org
Subject svn commit: r1372027 - in /apr/apr/branches/1.5.x: ./ time/win32/time.c
Date Sat, 11 Aug 2012 21:04:06 GMT
Author: trawick
Date: Sat Aug 11 21:04:05 2012
New Revision: 1372027

URL: http://svn.apache.org/viewvc?rev=1372027&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/1.5.x/   (props changed)
    apr/apr/branches/1.5.x/time/win32/time.c

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

Modified: apr/apr/branches/1.5.x/time/win32/time.c
URL: http://svn.apache.org/viewvc/apr/apr/branches/1.5.x/time/win32/time.c?rev=1372027&r1=1372026&r2=1372027&view=diff
==============================================================================
--- apr/apr/branches/1.5.x/time/win32/time.c (original)
+++ apr/apr/branches/1.5.x/time/win32/time.c Sat Aug 11 21:04:05 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