mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 14:54:52 +02:00
8215359: InnocuousForkJoinWorkerThread.setContextClassLoader needlessly throws
Reviewed-by: martin, chegar, dholmes, reinhapa, alanb
This commit is contained in:
parent
012c399c26
commit
a7ab4d7bd3
2 changed files with 26 additions and 11 deletions
|
@ -236,7 +236,8 @@ public class ForkJoinWorkerThread extends Thread {
|
|||
|
||||
@Override // paranoically
|
||||
public void setContextClassLoader(ClassLoader cl) {
|
||||
throw new SecurityException("setContextClassLoader");
|
||||
if (cl != null && ClassLoader.getSystemClassLoader() != cl)
|
||||
throw new SecurityException("setContextClassLoader");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue