-
Bug
-
Resolution: Fixed
-
P2
-
9-repo-jigsaw
A variant of this was reported by the ZeroTurnaround folks on jigsaw-dev.
The system property jdk.boot.class.path.append can be set/changed by:
1. -Xbootclasspath/a
2. An agent changing the value of the property in Agent_OnLoad
3. AddToBootstrapClassLoaderSearch
If we have all three, in this sequence, then the AddToBootstrapClassLoaderSearch property value set in #2 will be replaced. This needs to be investigated as there is potential corruption going on too, at least this is what has been suggested on the jigsaw-dev list.
The attached agent is one test case to demonstrate things, consider this:
java -Xbootclasspath/a:boot -agentlib:agent Test
The value printed should be boot:mydir:foo.jar but it actually prints boot:foo.jar.
Now change agent.c to comment out the usage of AddToBootstrapClassLoaderSearch, the test will correctly print boot:mydir.
The system property jdk.boot.class.path.append can be set/changed by:
1. -Xbootclasspath/a
2. An agent changing the value of the property in Agent_OnLoad
3. AddToBootstrapClassLoaderSearch
If we have all three, in this sequence, then the AddToBootstrapClassLoaderSearch property value set in #2 will be replaced. This needs to be investigated as there is potential corruption going on too, at least this is what has been suggested on the jigsaw-dev list.
The attached agent is one test case to demonstrate things, consider this:
java -Xbootclasspath/a:boot -agentlib:agent Test
The value printed should be boot:mydir:foo.jar but it actually prints boot:foo.jar.
Now change agent.c to comment out the usage of AddToBootstrapClassLoaderSearch, the test will correctly print boot:mydir.
- relates to
-
JDK-8224791 Value of jdk.boot.class.path.append system property has spurious separator before first element
-
- Closed
-