summaryrefslogtreecommitdiff
path: root/x11-clocks
diff options
context:
space:
mode:
authorGreg Lewis <glewis@FreeBSD.org>2004-04-02 17:08:49 +0000
committerGreg Lewis <glewis@FreeBSD.org>2004-04-02 17:08:49 +0000
commit608a1cc40c2aab7966a54f6f2ed42cbb3973882f (patch)
tree592378347a93c3e34ad8281c207dde1ebc127189 /x11-clocks
parentUpdate to version 0.3.6. (diff)
. Stop alarm going into an infinite loop in December.
PR: 60170 Submitted by: Alex <xfb52@dial.pipex.com>
Notes
Notes: svn path=/head/; revision=105972
Diffstat (limited to 'x11-clocks')
-rw-r--r--x11-clocks/xalarm/Makefile1
-rw-r--r--x11-clocks/xalarm/files/patch-dates.c18
2 files changed, 19 insertions, 0 deletions
diff --git a/x11-clocks/xalarm/Makefile b/x11-clocks/xalarm/Makefile
index c34284ee880f..1c6b82e38756 100644
--- a/x11-clocks/xalarm/Makefile
+++ b/x11-clocks/xalarm/Makefile
@@ -7,6 +7,7 @@
PORTNAME= xalarm
PORTVERSION= 3.06
+PORTREVISION= 1
CATEGORIES= x11-clocks
MASTER_SITES= ${MASTER_SITE_XCONTRIB}
MASTER_SITE_SUBDIR= utilities
diff --git a/x11-clocks/xalarm/files/patch-dates.c b/x11-clocks/xalarm/files/patch-dates.c
new file mode 100644
index 000000000000..76f76d908afb
--- /dev/null
+++ b/x11-clocks/xalarm/files/patch-dates.c
@@ -0,0 +1,18 @@
+--- dates.c.orig Fri Apr 2 09:08:14 2004
++++ dates.c Fri Apr 2 09:17:53 2004
+@@ -297,8 +297,13 @@
+ if (year >= 0) date->tm_year = year;
+ while ((year < 0) and (date->tm_year < (2500-1900)) and
+ (DaysBetween (&today, date) < 0))
+- if (month < 0)
+- date->tm_mon = (date->tm_mon + 1) % 12;
++ if (month < 0) {
++ date->tm_mon++;
++ if (date->tm_mon > 11) {
++ date->tm_mon = 0;
++ date->tm_year++;
++ }
++ }
+ else
+ date->tm_year++;
+ } else