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

Spec states to invoke the premain method in an agent class if it's public but implementation differs

XMLWordPrintable

      In the current implementation of sun/instrument/InstrumentationImpl.java, it allows the premain method be non-public which violates the spec. It should be fixed. It will break any existing java agent with a non-public static premain method that should be fixed. So this change should go into JDK 9 EA for external community testing.

      388 // the premain method should not be required to be public,
      389 // make it accessible so we can call it
      390 // Note: The spec says the following:
      391 // The agent class must implement a public static premain method...

            sspitsyn Serguei Spitsyn
            mchung Mandy Chung (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            8 Start watching this issue

              Created:
              Updated:
              Resolved: