aboutsummaryrefslogtreecommitdiffstats
path: root/lang/see/files/patch-libsee_obj__Date.c
diff options
context:
space:
mode:
Diffstat (limited to 'lang/see/files/patch-libsee_obj__Date.c')
-rw-r--r--lang/see/files/patch-libsee_obj__Date.c38
1 files changed, 7 insertions, 31 deletions
diff --git a/lang/see/files/patch-libsee_obj__Date.c b/lang/see/files/patch-libsee_obj__Date.c
index 12c3a0614c74..320710c4078a 100644
--- a/lang/see/files/patch-libsee_obj__Date.c
+++ b/lang/see/files/patch-libsee_obj__Date.c
@@ -1,35 +1,11 @@
---- libsee/obj_Date.c.orig Wed Jan 18 13:51:50 2006
-+++ libsee/obj_Date.c Mon Mar 27 10:56:41 2006
-@@ -2167,20 +2167,12 @@
- DaylightSavingTA(t)
+--- libsee/obj_Date.c.orig Sun May 7 06:43:55 2006
++++ libsee/obj_Date.c Tue Sep 5 09:11:09 2006
+@@ -335,7 +335,7 @@
+ struct SEE_interpreter *interp;
SEE_number_t t;
{
-- SEE_number_t ysec = t - TimeFromYear((SEE_number_t)YearFromTime(t));
-- int ily = InLeapYear(t);
-- int wstart = WeekDay(TimeFromYear((SEE_number_t)YearFromTime(t)));
-- int equiv_year = yearmap[ily][wstart];
- struct tm tm;
- time_t dst_time, nodst_time;
-+ time_t tt;
-+ tt=t/1000;
-+ tm=*localtime(&tt);
-
-- memset(&tm, 0, sizeof tm);
-- tm.tm_sec = SecFromTime(ysec);
-- tm.tm_min = MinFromTime(ysec);
-- tm.tm_hour = HourFromTime(ysec);
-- tm.tm_mday = DateFromTime(ysec);
-- tm.tm_mon = MonthFromTime(ysec) - 1;
-- tm.tm_year = equiv_year - 1900;
- tm.tm_isdst = -1;
-
- if (tm.tm_isdst == 0) return 0;
-@@ -2189,7 +2181,7 @@
- tm.tm_isdst = 0;
- nodst_time = mktime(&tm);
-
-- return (dst_time - nodst_time) * 1000;
-+ return -(dst_time - nodst_time) * 1000;
+- return t + LocalTZA(interp) + DaylightSavingTA(interp, t);
++ return t + LocalTZA(interp) - DaylightSavingTA(interp, t);
}
- static void
+ /*