mirror of
https://github.com/openjdk/jdk8u.git
synced 2025-12-10 10:44:16 -06:00
8314284: Enhance Nashorn performance
Co-authored-by: Francisco Ferrari Bihurriet <fferrari@redhat.com> Co-authored-by: Martin Balao Alonso <mbalao@redhat.com> Reviewed-by: andrew
This commit is contained in:
parent
7f5db81118
commit
5e0e2bf0ba
@ -1430,9 +1430,11 @@ public final class Global extends Scope {
|
||||
if ("context".equals(nameStr)) {
|
||||
return sctxt;
|
||||
} else if ("engine".equals(nameStr)) {
|
||||
// expose "engine" variable only when there is no security manager
|
||||
// or when no class filter is set.
|
||||
if (System.getSecurityManager() == null || global.getClassFilter() == null) {
|
||||
// expose "engine" variable only when there is no security manager,
|
||||
// or when no class filter is set and --no-java is not set
|
||||
if (System.getSecurityManager() == null ||
|
||||
(global.getClassFilter() == null &&
|
||||
!global.getContext().getEnv()._no_java)) {
|
||||
return global.engine;
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user