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

[HOST provider, not gregory] Return NULL when calling Calendar.getDisplayNames for Calendar.ERA

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: 8, 8u20, 9
    • Fix Version/s: 9
    • Component/s: core-libs
    • Environment:

      In my test, it's win2008r2 MUI.
      Locale is set to ja and calendar is set to Japanese calendar
      or Locale is set to th and calendar is set to Buddhist.

    • Subcomponent:
    • Introduced In Version:
      8
    • Resolved In Build:
      b101
    • CPU:
      generic
    • OS:
      windows

      Description

      Run the attached program (CalendarTest.java) on windows with locale set to Japanese and calendar set to Japanese calendar.

      When -Djava.locale.providers=HOST, the map got from "Map<String, Integer> map = cal.getDisplayNames(Calendar.ERA, Calendar.LONG, new Locale("ja", "JP", "JP"));" is null.

      Screen shot is also attached.

      If the locale provider is not HOST, there is no exception. If the calendar of the windows is Gregory, it also works fine. Same kind of problem also happens in windows th-TH with calendar set to Buddhist.

        Attachments

          Activity

            People

            • Assignee:
              naoto Naoto Sato
              Reporter:
              yhuang Yong Huang
            • Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: