jmeter-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r1518001 - /jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/proxy/Proxy.java
Date Tue, 27 Aug 2013 21:28:53 GMT
Author: sebb
Date: Tue Aug 27 21:28:53 2013
New Revision: 1518001

URL: http://svn.apache.org/r1518001
Log:
Localise variable definitions

Modified:
    jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/proxy/Proxy.java

Modified: jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/proxy/Proxy.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/proxy/Proxy.java?rev=1518001&r1=1518000&r2=1518001&view=diff
==============================================================================
--- jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/proxy/Proxy.java (original)
+++ jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/proxy/Proxy.java Tue Aug
27 21:28:53 2013
@@ -284,15 +284,12 @@ public class Proxy extends Thread {
             InputStream in = getCertificate();
             Exception except = null;
             if (in != null) {
-                KeyStore ks = null;
-                KeyManagerFactory kmf = null;
-                SSLContext sslcontext = null;
                 try {
-                    ks = KeyStore.getInstance(KEYSTORE_TYPE);
+                    KeyStore ks = KeyStore.getInstance(KEYSTORE_TYPE);
                     ks.load(in, JMeterUtils.getPropDefault("proxy.cert.keystorepass", DEFAULT_PASSWORD).toCharArray());
// $NON-NLS-1$
-                    kmf = KeyManagerFactory.getInstance(KEYMANAGERFACTORY);
+                    KeyManagerFactory kmf = KeyManagerFactory.getInstance(KEYMANAGERFACTORY);
                     kmf.init(ks, JMeterUtils.getPropDefault("proxy.cert.keypassword", DEFAULT_PASSWORD).toCharArray());
// $NON-NLS-1$
-                    sslcontext = SSLContext.getInstance(SSLCONTEXT_PROTOCOL);
+                    SSLContext sslcontext = SSLContext.getInstance(SSLCONTEXT_PROTOCOL);
                     sslcontext.init(kmf.getKeyManagers(), null, null);
                     SSLSocketFactory sslFactory = sslcontext.getSocketFactory();
                     hashHost.put(host, sslFactory);



Mime
View raw message