From c28f707f55a465fd7e005e16ce446b4adb367322 Mon Sep 17 00:00:00 2001
From: zzz <zzz@mail.i2p>
Date: Sun, 25 May 2014 19:23:04 +0000
Subject: [PATCH] cleanup

---
 .../java/src/net/i2p/i2ptunnel/I2PTunnelConnectClient.java  | 6 ------
 .../java/src/net/i2p/i2ptunnel/I2PTunnelHTTPClient.java     | 4 ++--
 .../java/src/net/i2p/i2ptunnel/I2PTunnelHTTPClientBase.java | 6 ++++++
 3 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelConnectClient.java b/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelConnectClient.java
index 45e530e6e5..7690e2c650 100644
--- a/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelConnectClient.java
+++ b/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelConnectClient.java
@@ -78,12 +78,6 @@ public class I2PTunnelConnectClient extends I2PTunnelHTTPClientBase implements R
          "Your browser is misconfigured. Do not use the proxy to access the router console or other localhost destinations.<BR>")
         .getBytes();
     
-    final static byte[] SUCCESS_RESPONSE =
-        ("HTTP/1.1 200 Connection Established\r\n"+
-         "Proxy-agent: I2P\r\n"+
-         "\r\n")
-        .getBytes();
-    
     /**
      * @throws IllegalArgumentException if the I2PTunnel does not contain
      *                                  valid config to contact the router
diff --git a/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelHTTPClient.java b/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelHTTPClient.java
index 389f0eb99e..ed4224ef34 100644
--- a/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelHTTPClient.java
+++ b/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelHTTPClient.java
@@ -966,7 +966,7 @@ public class I2PTunnelHTTPClient extends I2PTunnelHTTPClientBase implements Runn
                 byte[] response;
                 if (method.toUpperCase(Locale.US).equals("CONNECT")) {
                     data = null;
-                    response = I2PTunnelConnectClient.SUCCESS_RESPONSE;
+                    response = SUCCESS_RESPONSE;
                 } else {
                     data = newRequest.toString().getBytes("ISO-8859-1");
                     response = null;
@@ -1099,7 +1099,7 @@ public class I2PTunnelHTTPClient extends I2PTunnelHTTPClientBase implements Runn
                     response = null;
                 } else {
                     data = null;
-                    response = I2PTunnelConnectClient.SUCCESS_RESPONSE;
+                    response = SUCCESS_RESPONSE;
                 }
                 Thread t = new I2PTunnelRunner(s, i2ps, sockLock, data, response, mySockets, onTimeout);
                 t.start();
diff --git a/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelHTTPClientBase.java b/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelHTTPClientBase.java
index b00611311a..7fb82c5bcb 100644
--- a/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelHTTPClientBase.java
+++ b/apps/i2ptunnel/java/src/net/i2p/i2ptunnel/I2PTunnelHTTPClientBase.java
@@ -93,6 +93,12 @@ public abstract class I2PTunnelHTTPClientBase extends I2PTunnelClientBase implem
             "be temporarily offline.  You may want to <b>retry</b>.  " +
             "Could not find the following Destination:<BR><BR><div>").getBytes();
 
+    protected final static byte[] SUCCESS_RESPONSE =
+        ("HTTP/1.1 200 Connection Established\r\n"+
+         "Proxy-agent: I2P\r\n"+
+         "\r\n")
+        .getBytes();
+
     private final byte[] _proxyNonce;
     private final ConcurrentHashMap<String, NonceInfo> _nonces;
     private final AtomicInteger _nonceCleanCounter = new AtomicInteger();
-- 
GitLab