]> Cypherpunks repositories - gostls13.git/commit
[release-branch.go1.15] time: fix LoadLocationFromTZData with slim tzdata
authorChristopher Hlubek <christopher.hlubek@networkteam.com>
Mon, 26 Oct 2020 12:44:44 +0000 (13:44 +0100)
committerIan Lance Taylor <iant@golang.org>
Thu, 29 Oct 2020 22:30:25 +0000 (22:30 +0000)
commit5b023e693ff8058bcffe7103d7ddd120910af692
tree185578d2267168aee7b3572c18812b33aed2a431
parent414668cfbc41fd8cadf74e981849d1e05cc23b2e
[release-branch.go1.15] time: fix LoadLocationFromTZData with slim tzdata

The extend information of a time zone file with last transition < now
could result in a wrong cached zone because it used the zone of the
last transition.

This could lead to wrong zones in systems with slim zoneinfo.

For #42216
Fixes #42138

Change-Id: I7c57c35b5cfa58482ac7925b5d86618c52f5444d
Reviewed-on: https://go-review.googlesource.com/c/go/+/264939
Trust: Tobias Klauser <tobias.klauser@gmail.com>
Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com>
TryBot-Result: Go Bot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
(cherry picked from commit 70e022e4a83dc996ac4f108e811fbc399ad5565b)
Reviewed-on: https://go-review.googlesource.com/c/go/+/266299
Trust: Ian Lance Taylor <iant@golang.org>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Tobias Klauser <tobias.klauser@gmail.com>
src/time/zoneinfo_read.go
src/time/zoneinfo_test.go