jmeter-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fschumac...@apache.org
Subject svn commit: r1856124 - /jmeter/trunk/src/core/org/apache/jmeter/util/SSLManager.java
Date Sat, 23 Mar 2019 19:21:52 GMT
Author: fschumacher
Date: Sat Mar 23 19:21:52 2019
New Revision: 1856124

URL: http://svn.apache.org/viewvc?rev=1856124&view=rev
Log:
Correct synchronized usage of field

Most of the time the file keyStore was already used inside a synchronized block and volatile
is not a good idea to be used for non primitive types, so use synchronized for the rest of
the
simple methods that use keyStore as field.

Followup to r1856123. Now remove the volatile keyword, really.


Modified:
    jmeter/trunk/src/core/org/apache/jmeter/util/SSLManager.java

Modified: jmeter/trunk/src/core/org/apache/jmeter/util/SSLManager.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/util/SSLManager.java?rev=1856124&r1=1856123&r2=1856124&view=diff
==============================================================================
--- jmeter/trunk/src/core/org/apache/jmeter/util/SSLManager.java (original)
+++ jmeter/trunk/src/core/org/apache/jmeter/util/SSLManager.java Sat Mar 23 19:21:52 2019
@@ -68,7 +68,7 @@ public abstract class SSLManager {
     private JmeterKeyStore keyStore;
 
     /** Cache the TrustStore instance - null if no truststore name was provided */
-    private volatile KeyStore trustStore = null;
+    private KeyStore trustStore = null;
     // Have we yet tried to load the truststore?
     private volatile boolean truststoreLoaded=false;
 



Mime
View raw message