1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-01-10 15:56:18 +00:00

(timezone-fix-time): For year values < 50, add 2000.

This commit is contained in:
Richard M. Stallman 1994-12-26 01:24:38 +00:00
parent 448b61c92a
commit 13d76d1ca5

View File

@ -291,7 +291,11 @@ If LOCAL is nil, it is assumed to be GMT.
If TIMEZONE is nil, use the local time zone."
(let* ((date (timezone-parse-date date))
(year (string-to-int (aref date 0)))
(year (if (< year 100) (+ year 1900) year))
(year (cond ((< year 50)
(+ year 2000))
((< year 100)
(+ year 1900))
(t year)))
(month (string-to-int (aref date 1)))
(day (string-to-int (aref date 2)))
(time (timezone-parse-time (aref date 3)))