JDK-8196215 : sun/security/util/Resources/customSysClassLoader/MessageFormatting.java failed on ar_SA locale.
  • Type: Bug
  • Component: security-libs
  • Sub-Component: java.security
  • Affected Version: 10
  • Priority: P4
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2018-01-26
  • Updated: 2018-02-16
  • Resolved: 2018-02-08
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 11
11 b01Fixed
Related Reports
Relates :  
Description
Test build: JDK 10 build 41
Test env: Mac 10.13 with ar_SA locale. 

Error message:
Expected string:
line \u0660: \u0661
Actual string:
line 0: 1
java.lang.Exception: Incorrect message string
	at MessageFormatting.main(MessageFormatting.java:55)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:564)
	at com.sun.javatest.regtest.agent.MainWrapper$MainThread.run(MainWrapper.java:115)
	at java.base/java.lang.Thread.run(Thread.java:844)

JavaTest Message: Test threw exception: java.lang.Exception: Incorrect message string
JavaTest Message: shutting down test

STATUS:Failed.`main' threw exception: java.lang.Exception: Incorrect message string

L65: MessageFormat format = new MessageFormat(str) uses system default locale which is ar_SA to construct a MessageFormat which uses ARABIC-INDIC digits(\u0660~\u0669), not (0~9) to display the numbers.
Suggest to use MessageFormat���(String pattern, Locale locale) and specify en_US locale to construct a MessageFormat.


Comments
RULE "sun/security/util/Resources/customSysClassLoader/MessageFormatting.java" any any
26-01-2018