Details
-
Bug
-
Resolution: Fixed
-
P4
-
18
-
b26
Backports
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8282488 | 17.0.4-oracle | Sean Coffey | P4 | Resolved | Fixed | b01 |
JDK-8283302 | 17.0.4 | Goetz Lindenmaier | P4 | Resolved | Fixed | b01 |
Description
if (nameToVersion.containsKey(name)) {
if (!version.equals(nameToVersion.get(name))) {
throw new MultiReleaseException(
"err.multirelease.version.associated",
name, nameToVersion.get(name), version
);
}
} else {
nameToVersion.put(name, version);
}
2 threads might be running this code concurrently. Both threads could first run the nameToVersion.containsKey(name) check, see false as the result, and then both continue to the else block to put the result in the nameToVersion map, where 1 of the 2 threads will end up overwriting the value the other thread inserted.
Attachments
Issue Links
- backported by
-
JDK-8282488 Data race in jdeps VersionHelper
-
- Resolved
-
-
JDK-8283302 Data race in jdeps VersionHelper
-
- Resolved
-
- relates to
-
JDK-8277564 jdeps --print-module-deps fails with --multi-release
-
- Resolved
-
-
JDK-8277165 jdeps --multi-release --print-module-deps fails if module-info.class in different versioned directories
-
- Resolved
-
- links to
-
Commit openjdk/jdk17u-dev/defd25c9
-
Commit openjdk/jdk/7e54d065
-
Review openjdk/jdk17u-dev/256
-
Review openjdk/jdk17u/314
-
Review openjdk/jdk/6530