]> git.netwichtig.de Git - user/henk/code/snooze.git/commitdiff
find_next: take leap year into account (e.g. when using dayofyear)
authorLeah Neukirchen <leah@vuxu.org>
Tue, 29 Aug 2017 15:41:44 +0000 (17:41 +0200)
committerLeah Neukirchen <leah@vuxu.org>
Tue, 29 Aug 2017 15:41:44 +0000 (17:41 +0200)
snooze.c

index b29c7b622817d86a93e13114ddaea2a3ce005f18..f37c42ac2a386453b9db812c59e97aa8d0dea0ed 100644 (file)
--- a/snooze.c
+++ b/snooze.c
@@ -185,7 +185,7 @@ next_day:
                tm->tm_hour = 0;
 
                t = mktime(tm);
-               if (t > from+(365*24*60*60))  // no result within a year
+               if (t > from+(366*24*60*60))  // no result within a year
                        return -1;
        }