From: Derick Rethans Date: Mon, 28 Jun 2004 14:33:57 +0000 (+0000) Subject: - Fixed bug with leap year checking. X-Git-Tag: php-5.0.0~108 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=da2a1977b56afa8d457d5527868927e854bb5c9e;p=php - Fixed bug with leap year checking. --- diff --git a/ext/standard/datetime.c b/ext/standard/datetime.c index d033612499..4e455a86a0 100644 --- a/ext/standard/datetime.c +++ b/ext/standard/datetime.c @@ -64,7 +64,7 @@ static int phpday_tab[2][12] = { {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)