From 628430e63f561fe4a35baad5290f92101d3bcaac Mon Sep 17 00:00:00 2001 From: "cyeh%netscape.com" Date: Tue, 1 Sep 1998 01:31:32 +0000 Subject: [PATCH] FTSO MacPerl. Dates are implemented in the non-standard way of starting from 1904 instead of 1970. As a result, we must add back those lost years in order to get cross platform compatibility with other perl time implementations. Please shoot me. --- config/mac-set-timebomb.pl | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/config/mac-set-timebomb.pl b/config/mac-set-timebomb.pl index 6a193574902..9d78085d176 100644 --- a/config/mac-set-timebomb.pl +++ b/config/mac-set-timebomb.pl @@ -106,6 +106,12 @@ sub set_bomb { unless ($warning_days < $bomb_days); my $now = time; + +# MacPerl stores date and times from 1904 instead of 1970 +# Let's do the timewarp again! + + $now = $now + (66 * 365 * 24 * 60 * 60); + my $bomb = $now + ($bomb_days * 24 * 60 * 60); my $warn = $now + ($warning_days * 24 * 60 * 60);