static
This commit is contained in:
@ -151,7 +151,7 @@ public class I2PTunnelHTTPServer extends I2PTunnelServer {
|
|||||||
_log.warn("Took a while to handle the request [" + timeToHandle + ", socket create: " + (afterSocket-afterAccept) + "]");
|
_log.warn("Took a while to handle the request [" + timeToHandle + ", socket create: " + (afterSocket-afterAccept) + "]");
|
||||||
}
|
}
|
||||||
|
|
||||||
private class CompressedRequestor implements Runnable {
|
private static class CompressedRequestor implements Runnable {
|
||||||
private Socket _webserver;
|
private Socket _webserver;
|
||||||
private I2PSocket _browser;
|
private I2PSocket _browser;
|
||||||
private String _headers;
|
private String _headers;
|
||||||
@ -214,7 +214,8 @@ public class I2PTunnelHTTPServer extends I2PTunnelServer {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
private class Sender implements Runnable {
|
|
||||||
|
private static class Sender implements Runnable {
|
||||||
private OutputStream _out;
|
private OutputStream _out;
|
||||||
private InputStream _in;
|
private InputStream _in;
|
||||||
private String _name;
|
private String _name;
|
||||||
@ -248,7 +249,8 @@ public class I2PTunnelHTTPServer extends I2PTunnelServer {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
private class CompressedResponseOutputStream extends HTTPResponseOutputStream {
|
|
||||||
|
private static class CompressedResponseOutputStream extends HTTPResponseOutputStream {
|
||||||
private InternalGZIPOutputStream _gzipOut;
|
private InternalGZIPOutputStream _gzipOut;
|
||||||
public CompressedResponseOutputStream(OutputStream o) {
|
public CompressedResponseOutputStream(OutputStream o) {
|
||||||
super(o);
|
super(o);
|
||||||
@ -287,7 +289,8 @@ public class I2PTunnelHTTPServer extends I2PTunnelServer {
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
private class InternalGZIPOutputStream extends GZIPOutputStream {
|
|
||||||
|
private static class InternalGZIPOutputStream extends GZIPOutputStream {
|
||||||
public InternalGZIPOutputStream(OutputStream target) throws IOException {
|
public InternalGZIPOutputStream(OutputStream target) throws IOException {
|
||||||
super(target);
|
super(target);
|
||||||
}
|
}
|
||||||
@ -309,7 +312,7 @@ public class I2PTunnelHTTPServer extends I2PTunnelServer {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private String formatHeaders(Properties headers, StringBuilder command) {
|
private static String formatHeaders(Properties headers, StringBuilder command) {
|
||||||
StringBuilder buf = new StringBuilder(command.length() + headers.size() * 64);
|
StringBuilder buf = new StringBuilder(command.length() + headers.size() * 64);
|
||||||
buf.append(command.toString().trim()).append("\r\n");
|
buf.append(command.toString().trim()).append("\r\n");
|
||||||
for (Iterator iter = headers.keySet().iterator(); iter.hasNext(); ) {
|
for (Iterator iter = headers.keySet().iterator(); iter.hasNext(); ) {
|
||||||
|
@ -170,7 +170,7 @@ public class I2PTunnelIRCServer extends I2PTunnelServer implements Runnable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/** keep reading until we see USER or SERVER */
|
/** keep reading until we see USER or SERVER */
|
||||||
private String filterRegistration(InputStream in, String newHostname) throws IOException {
|
private static String filterRegistration(InputStream in, String newHostname) throws IOException {
|
||||||
StringBuilder buf = new StringBuilder(128);
|
StringBuilder buf = new StringBuilder(128);
|
||||||
int lineCount = 0;
|
int lineCount = 0;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user