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

jdeprscan --help causes an exception when the locale is ja, zh_CN or de

XMLWordPrintable

    • 19
    • b19
    • generic
    • generic

        Running jdeprscan with --help option causes an exception on any OSs when the locale is ja or zh_CN.

        $ jdeprscan -J-Duser.language=ja --help
        Exception in thread "main" java.lang.IllegalArgumentException: can't parse argument number: dir|jar|class
                at java.base/java.text.MessageFormat.makeFormat(MessageFormat.java:1454)
                at java.base/java.text.MessageFormat.applyPattern(MessageFormat.java:492)
                at java.base/java.text.MessageFormat.<init>(MessageFormat.java:371)
                at java.base/java.text.MessageFormat.format(MessageFormat.java:860)
                at jdk.jdeps/com.sun.tools.jdeprscan.Messages.get(Messages.java:62)
                at jdk.jdeps/com.sun.tools.jdeprscan.Main.printHelp(Main.java:706)
                at jdk.jdeps/com.sun.tools.jdeprscan.Main.run(Main.java:529)
                at jdk.jdeps/com.sun.tools.jdeprscan.Main.call(Main.java:717)
                at jdk.jdeps/com.sun.tools.jdeprscan.Main.main(Main.java:725)
        Caused by: java.lang.NumberFormatException: For input string: "dir|jar|class"
                at java.base/java.lang.NumberFormatException.forInputString(NumberFormatException.java:67)
                at java.base/java.lang.Integer.parseInt(Integer.java:668)
                at java.base/java.lang.Integer.parseInt(Integer.java:786)
                at java.base/java.text.MessageFormat.makeFormat(MessageFormat.java:1452)
                ... 8 more

        $ jdeprscan -J-Duser.language=zh -J-Duser.country=CN --help
        Exception in thread "main" java.lang.IllegalArgumentException: can't parse argument number: dir|jar|class
                at java.base/java.text.MessageFormat.makeFormat(MessageFormat.java:1454)
                at java.base/java.text.MessageFormat.applyPattern(MessageFormat.java:492)
                at java.base/java.text.MessageFormat.<init>(MessageFormat.java:371)
                at java.base/java.text.MessageFormat.format(MessageFormat.java:860)
                at jdk.jdeps/com.sun.tools.jdeprscan.Messages.get(Messages.java:62)
                at jdk.jdeps/com.sun.tools.jdeprscan.Main.printHelp(Main.java:706)
                at jdk.jdeps/com.sun.tools.jdeprscan.Main.run(Main.java:529)
                at jdk.jdeps/com.sun.tools.jdeprscan.Main.call(Main.java:717)
                at jdk.jdeps/com.sun.tools.jdeprscan.Main.main(Main.java:725)
        Caused by: java.lang.NumberFormatException: For input string: "dir|jar|class"
                at java.base/java.lang.NumberFormatException.forInputString(NumberFormatException.java:67)
                at java.base/java.lang.Integer.parseInt(Integer.java:668)
                at java.base/java.lang.Integer.parseInt(Integer.java:786)
                at java.base/java.text.MessageFormat.makeFormat(MessageFormat.java:1452)
                ... 8 more

        Of course, it works well when the locale is anything other than those locales.

              ksakata Koichi Sakata
              ksakata Koichi Sakata
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: