When a shared archive is constructed and reloaded, the PackageInfo hash table
contained in src/share/vm/runtime/classLoader.cpp is lost. This causes
subsequent calls to java.lang.Package.getSystemPackage() to return null where
they used to return a Package object.
There are a fair number of implicit assumptions in the Package code that if a
class is loaded from a flat file (rather than from a directory) then it is
contained in a jar file. These assumptions will be violated if the shared
archive's file name is placed inside the PackageInfo. However, this will not
cause the Java-level package code to break, only to throw exceptions internally
and return null for some values. Plausibly the shared archive should record the
package information in one of its sections, though this is not high priority
as null is a valid return value from Class.getPackage().
contained in src/share/vm/runtime/classLoader.cpp is lost. This causes
subsequent calls to java.lang.Package.getSystemPackage() to return null where
they used to return a Package object.
There are a fair number of implicit assumptions in the Package code that if a
class is loaded from a flat file (rather than from a directory) then it is
contained in a jar file. These assumptions will be violated if the shared
archive's file name is placed inside the PackageInfo. However, this will not
cause the Java-level package code to break, only to throw exceptions internally
and return null for some values. Plausibly the shared archive should record the
package information in one of its sections, though this is not high priority
as null is a valid return value from Class.getPackage().
- relates to
-
JDK-5048142 Regression-cte CTE_REGTEST/Generic/4893051/packinfo.java fails
- Closed
-
JDK-4932897 Share W/S: NPE in sun.java2d.loops.GraphicsPrimitiveProxy.instantiate
- Closed
-
JDK-4932965 Share W/S: Regression test .../ImageTransferTest.html fails
- Closed