RFR: 8356450: NPE in CLDRTimeZoneNameProviderImpl for tzdata downgrades after JDK-8342550
Brian Burkhalter
bpb at openjdk.org
Thu May 8 21:37:52 UTC 2025
On Thu, 8 May 2025 20:50:25 GMT, Naoto Sato <naoto at openjdk.org> wrote:
> Fixing the NPE in CLDR time zone name provider. The NPE occurrs if the time zone data was downgraded by the TZUpdater tool in which some time zones are missing. For those missing zones, `ZoneInfo.getTimeZone()` returns null, while `TimeZone.getTimeZone()` falls back to `GMT`, which was the case prior to JDK-8342550. Changed the code in CLDR provider to assume the fixed zone in such a case.
> Manually confirmed the fix, and no test case is provided, as it requires tweaking the JDK with TZUpdater.
Looks all right to me.
-------------
Marked as reviewed by bpb (Reviewer).
PR Review: https://git.openjdk.org/jdk/pull/25130#pullrequestreview-2826417729
More information about the core-libs-dev
mailing list