ECMA (sort of) fix to 156615, platform-dependent troubles on Solaris.

There was a check in our mini-nspr against asking the OS time services
what the DST offset was for time 0... but the check didn't do what the
comment said it did.  So we got the wrong DST offset for... (drum roll
please) the two seconds on either side of the eve of 1970 GMT.

I have a similar fix ready for prmjtime.c, but I'll wait until the
stability freeze settles down.
This commit is contained in:
mccabe 1998-06-20 01:21:01 +00:00
Родитель fa762dbebf
Коммит 54e0d585a2
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -373,7 +373,7 @@ PR_DSTOffset(int64 time)
if (LL_CMP(time,>,maxtimet)) {
LL_UI2L(time,PR_MAX_UNIX_TIMET);
} else if (!LL_GE_ZERO(time)) {
} else if (!LL_GE_ZERO(time) || LL_IS_ZERO(time)) {
/* go ahead a day to make localtime work (does not work with 0) */
LL_UI2L(time,PR_DAY_SECONDS);
}