jmeter-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pmoua...@apache.org
Subject svn commit: r1709166 - /jmeter/trunk/src/functions/org/apache/jmeter/functions/JavaScript.java
Date Sat, 17 Oct 2015 13:46:31 GMT
Author: pmouawad
Date: Sat Oct 17 13:46:31 2015
New Revision: 1709166

URL: http://svn.apache.org/viewvc?rev=1709166&view=rev
Log:
Bug 58477 - __javaScript function : Allow use of Nashorn engine for Java8 and upper versions
Take into account sebb feedback
Bugzilla Id: 58477

Modified:
    jmeter/trunk/src/functions/org/apache/jmeter/functions/JavaScript.java

Modified: jmeter/trunk/src/functions/org/apache/jmeter/functions/JavaScript.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/functions/org/apache/jmeter/functions/JavaScript.java?rev=1709166&r1=1709165&r2=1709166&view=diff
==============================================================================
--- jmeter/trunk/src/functions/org/apache/jmeter/functions/JavaScript.java (original)
+++ jmeter/trunk/src/functions/org/apache/jmeter/functions/JavaScript.java Sat Oct 17 13:46:31
2015
@@ -58,13 +58,13 @@ public class JavaScript extends Abstract
     }
  
     private static final boolean USE_RHINO_ENGINE = 
-            getInstance().getEngineByName(JavaScript.NASHORN_ENGINE_NAME) == null ||
-            JMeterUtils.getPropDefault(USE_RHINO_ENGINE_PROPERTY, true) ;
+            JMeterUtils.getPropDefault(USE_RHINO_ENGINE_PROPERTY, true) || 
+            (getInstance().getEngineByName(JavaScript.NASHORN_ENGINE_NAME) == null);
 
     /**
      * @return ScriptEngineManager singleton
      */
-    public static ScriptEngineManager getInstance() {
+    private static ScriptEngineManager getInstance() {
             return LazyHolder.INSTANCE;
     }
     private static final List<String> desc = new LinkedList<>();



Mime
View raw message