fix leap year calculation

This commit is contained in:
Matt Jacob 2000-01-04 03:27:04 +00:00
parent 7e5b33c6cd
commit ae075f7fb7

View File

@ -63,7 +63,8 @@
#define SECDAY ((unsigned)(24*SECHOUR)) /* seconds per day */
#define SECYR ((unsigned)(365*SECDAY)) /* seconds per common year */
#define LEAPYEAR(year) (((year) % 4) == 0)
#define LEAPYEAR(y) \
(((y) % 4) == 0 && (((y) % 100) != 0 || ((y) % 400) == 0))
device_t clockdev;
int clockinitted;