(9) RFR: 8179515: Class java.util.concurrent.ThreadLocalRandom fails to Initialize when using SecurityManager
claes.redestad at oracle.com
Thu May 11 21:01:28 UTC 2017
The null check is redundant, so the code could be simplified a bit.
On 2017-05-11 22:46, David Holmes wrote:
> Bug: https://bugs.openjdk.java.net/browse/JDK-8179515
> webrev: http://cr.openjdk.java.net/~dholmes/8179515/webrev/
> This is a fix contributed by Doug Lea, from a suggestion made by Alan
> Bateman. While I'm handling the fix process for Doug, it isn't my fix
> so I am also a Reviewer of this fix. I expect Martin to also review.
> The fix is quite simple - break the dependency between
> ThreadLocalRandom and the security framework by replacing a
> doPrivileged block that reads a system property with a call to the JDK
> internal VM.getSavedProperty(). This allows TLR to be used
> transitively from the security framework without creating a cyclic
> initialization dependency which leads to failure to initialize.
> This fixed is approved for 9.
More information about the core-libs-dev