derick          Mon Jun 28 10:33:57 2004 EDT

  Modified files:              
    /php-src/ext/standard       datetime.c 
  Log:
  - Fixed bug with leap year checking.
  
  
http://cvs.php.net/diff.php/php-src/ext/standard/datetime.c?r1=1.120&r2=1.121&ty=u
Index: php-src/ext/standard/datetime.c
diff -u php-src/ext/standard/datetime.c:1.120 php-src/ext/standard/datetime.c:1.121
--- php-src/ext/standard/datetime.c:1.120       Wed Mar 31 12:57:33 2004
+++ php-src/ext/standard/datetime.c     Mon Jun 28 10:33:57 2004
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: datetime.c,v 1.120 2004/03/31 17:57:33 hholzgra Exp $ */
+/* $Id: datetime.c,v 1.121 2004/06/28 14:33:57 derick Exp $ */
 
 #include "php.h"
 #include "zend_operators.h"
@@ -64,7 +64,7 @@
        {31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31}
 };
 
-#define isleap(year) (((year % 4) == 0 && (year % 100) != 0) || (year % 400)==0)
+#define isleap(year) ((((year) % 4) == 0 && ((year) % 100) != 0) || ((year) % 400)==0)
 #define YEAR_BASE 1900
 
 /* {{{ proto int time(void)

-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to