patch-2.4.19 linux-2.4.19/arch/ppc/kernel/time.c

Next file: linux-2.4.19/arch/ppc/lib/string.S
Previous file: linux-2.4.19/arch/ppc/kernel/syscalls.c
Back to the patch index
Back to the overall index

diff -urN linux-2.4.18/arch/ppc/kernel/time.c linux-2.4.19/arch/ppc/kernel/time.c
@@ -358,7 +358,7 @@
 #define	STARTOFTIME		1970
 #define SECDAY			86400L
 #define SECYR			(SECDAY * 365)
-#define	leapyear(year)		((year) % 4 == 0)
+#define	leapyear(y)		((!(y % 4) && (y % 100)) || !(y % 400))
 #define	days_in_year(a) 	(leapyear(a) ? 366 : 365)
 #define	days_in_month(a) 	(month_days[(a) - 1])
 

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)