Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8341484

TimeZone.toZoneId() throws exception when using old mapping for "HST"

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: P4 P4
    • 24
    • 24
    • core-libs
    • None

      TimeZone.toZoneId() throws exception for "HST" when the old mapping is used.

      The culprit is in TimeZone.toZoneId0().

      This method provides workarounds for "EST", "MST", and "HST" when the old mapping system property is true. However, it seems that "HST" was added with "America/Honolulu" when it should have been "Pacific/Honolulu".

      Reproducer,

      Set the system property "sun.timezone.ids.oldmapping" as true.
      Then run, TimeZone.getTimeZone("MST").toZoneId()

            jlu Justin Lu
            jlu Justin Lu
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: