head 1.2; access; symbols pkgsrc-2020Q3:1.1.0.4 pkgsrc-2020Q3-base:1.1 pkgsrc-2020Q2:1.1.0.2 pkgsrc-2020Q2-base:1.1; locks; strict; comment @// @; 1.2 date 2020.11.21.09.45.39; author wiz; state dead; branches; next 1.1; commitid 9den0ljxmrNJMJwC; 1.1 date 2020.04.05.06.10.28; author wiz; state Exp; branches; next ; commitid Pwl0cOGoWdLqZ93C; desc @@ 1.2 log @mozjs60: remove Use mozjs68 or mozjs78 instead. No package in pkgsrc still needs this version. @ text @$NetBSD: patch-jsdate.cpp,v 1.1 2020/04/05 06:10:28 wiz Exp $ Always use the equivalent year to determine the time zone offset and name Reviewed-by: Jeff Walden Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1415202 Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1479687 Origin: upstream Applied-upstream: 62, commit:https://hg.mozilla.org/mozilla-central/rev/ce9f1466ec78 --- jsdate.cpp.orig 2019-07-01 09:07:41.000000000 +0000 +++ jsdate.cpp @@@@ -2353,12 +2353,16 @@@@ static PRMJTime ToPRMJTime(double localT static size_t FormatTime(char* buf, int buflen, const char* fmt, double utcTime, double localTime) { PRMJTime prtm = ToPRMJTime(localTime, utcTime); - int eqivalentYear = IsRepresentableAsTime32(utcTime) - ? prtm.tm_year - : EquivalentYearForDST(prtm.tm_year); + + // If an equivalent year was used to compute the date/time components, use + // the same equivalent year to determine the time zone name and offset in + // PRMJ_FormatTime(...). + int timeZoneYear = IsRepresentableAsTime32(utcTime) + ? prtm.tm_year + : EquivalentYearForDST(prtm.tm_year); int offsetInSeconds = (int)floor((localTime - utcTime) / msPerSecond); - return PRMJ_FormatTime(buf, buflen, fmt, &prtm, eqivalentYear, + return PRMJ_FormatTime(buf, buflen, fmt, &prtm, timeZoneYear, offsetInSeconds); } @ 1.1 log @lang/mozjs60: import mozjs60-60.8.0 I've named this mozjs60 to match what Linux distributions, in particular Debian, do. Previous versions in pkgsrc are called spidermonkey* This directory contains SpiderMonkey 60, the JavaScript engine by Mozilla. @ text @d1 1 a1 1 $NetBSD$ @