-
Bug
-
Resolution: Fixed
-
P3
-
9
-
b153
-
generic
-
generic
-
Verified
Here's what I/we found when running "jmod hash".
As background:
jdk.jdeps requires jdk.compiler
jdk.compiler requires java.compiler
Running this:
% cd build/windows*/images/jmods
% jmod.exe hash --mp . --hash-modules \
"jdk.jdeps|jdk.compiler|java.compiler"
updates two files:
jdk.compiler.jmod
adds "hash jdk.jdeps"
updates timestamp (zip file offset 10-14)
java.compiler.jmod
adds "hash jdk.[compiler,jdeps]"
updates timestamp (zip file offset 10-14)
But note that when the hash for jdk.compiler.jmod was calculated to add to java.compiler.jmod, it used the original file/internal timestamp, not the updated/soon-to-be-written one. So if you now try to run jlink, the stored java.compiler signature for jdk.compiler.jmod won't match.
So my question is:
Mandy wrote:
> But I would expect only java.compiler will record the hashes.
Was jdk.compiler.jmod also supposed to be updated in the "jmod hash" above?
If no, you have a bug because it is being updated.
If yes, you have a bug in that you're calculating jdk.compiler pre-update.
I'm just not sure which one is the expected behavior.
As background:
jdk.jdeps requires jdk.compiler
jdk.compiler requires java.compiler
Running this:
% cd build/windows*/images/jmods
% jmod.exe hash --mp . --hash-modules \
"jdk.jdeps|jdk.compiler|java.compiler"
updates two files:
jdk.compiler.jmod
adds "hash jdk.jdeps"
updates timestamp (zip file offset 10-14)
java.compiler.jmod
adds "hash jdk.[compiler,jdeps]"
updates timestamp (zip file offset 10-14)
But note that when the hash for jdk.compiler.jmod was calculated to add to java.compiler.jmod, it used the original file/internal timestamp, not the updated/soon-to-be-written one. So if you now try to run jlink, the stored java.compiler signature for jdk.compiler.jmod won't match.
So my question is:
Mandy wrote:
> But I would expect only java.compiler will record the hashes.
Was jdk.compiler.jmod also supposed to be updated in the "jmod hash" above?
If no, you have a bug because it is being updated.
If yes, you have a bug in that you're calculating jdk.compiler pre-update.
I'm just not sure which one is the expected behavior.
- relates to
-
JDK-8173096 jmod files are not world-readable
-
- Closed
-
-
JDK-8172870 test/tools/jmod/JmodTest.java fails on windows with AccessDeniedException
-
- Closed
-