hc-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject svn commit: r1023974 - /httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/auth/NTLMEngineImpl.java
Date Mon, 18 Oct 2010 20:09:40 GMT
Author: sebb
Date: Mon Oct 18 20:09:39 2010
New Revision: 1023974

URL: http://svn.apache.org/viewvc?rev=1023974&view=rev
Log:
Make private immutable variable final
Missing @Override markers

Modified:
    httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/auth/NTLMEngineImpl.java

Modified: httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/auth/NTLMEngineImpl.java
URL: http://svn.apache.org/viewvc/httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/auth/NTLMEngineImpl.java?rev=1023974&r1=1023973&r2=1023974&view=diff
==============================================================================
--- httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/auth/NTLMEngineImpl.java
(original)
+++ httpcomponents/httpclient/trunk/httpclient/src/main/java/org/apache/http/impl/auth/NTLMEngineImpl.java
Mon Oct 18 20:09:39 2010
@@ -56,12 +56,14 @@ final class NTLMEngineImpl implements NT
     protected final static int FLAG_NEGOTIATE_KEY_EXCH = 0x40000000;
 
     /** Secure random generator */
-    private static java.security.SecureRandom RND_GEN;
+    private static final java.security.SecureRandom RND_GEN;
     static {
+        java.security.SecureRandom rnd = null;
         try {
-            RND_GEN = java.security.SecureRandom.getInstance("SHA1PRNG");
+            rnd = java.security.SecureRandom.getInstance("SHA1PRNG");
         } catch (Exception e) {
         }
+        RND_GEN = rnd;
     }
 
     /** Character encoding */
@@ -774,6 +776,7 @@ final class NTLMEngineImpl implements NT
          * Getting the response involves building the message before returning
          * it
          */
+        @Override
         String getResponse() {
             // Now, build the message. Calculate its length first, including
             // signature or type.
@@ -951,6 +954,7 @@ final class NTLMEngineImpl implements NT
         }
 
         /** Assemble the response */
+        @Override
         String getResponse() {
             int ntRespLen = ntResp.length;
             int lmRespLen = lmResp.length;



Mime
View raw message