Uploaded image for project: 'Code Tools'
  1. Code Tools
  2. CODETOOLS-7901791

Console encoding detection code is broken with upcoming setAccessible changes

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: tools
    • Labels:
      None
    • Subcomponent:
      jmh

      Description

      See:
       http://mail.openjdk.java.net/pipermail/jmh-dev/2016-September/002330.html

      Exception in thread "main"
      java.lang.reflect.InaccessibleObjectException: Unable to make private
      java.nio.charset.Charset java.io.Console.cs accessible: module java.base
      does not "exports private java.io" to unnamed module @78e67e0a
      at
      java.base/jdk.internal.reflect.Reflection.throwInaccessibleObjectException(Reflection.java:414)
      at
      java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:196)
      at java.base/java.lang.reflect.Field.checkCanSetAccessible(Field.java:171)
      at java.base/java.lang.reflect.Field.setAccessible(Field.java:165)
      at org.openjdk.jmh.util.Utils.guessConsoleEncoding(Utils.java:205)
      at org.openjdk.jmh.runner.Runner.createOutputFormat(Runner.java:106)
      at org.openjdk.jmh.runner.Runner.<init>(Runner.java:87)
      at org.openjdk.jmh.Main.main(Main.java:43)

        Attachments

          Activity

            People

            • Assignee:
              shade Aleksey Shipilev
              Reporter:
              shade Aleksey Shipilev
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: