2005-03-04 jrandom

* Filter HTTP response headers in the eepproxy, forcing Connection: close
      so that broken (/malicious) webservers can't allow persistent
      connections.  All HTTP compliant browsers should now always close the
      socket.
    * Enabled the GZIPInputStream's cache (they were'nt cached before)
    * Make sure our first send is always a SYN (duh)
    * Workaround for some buggy compilers
This commit is contained in:
jrandom
2005-03-05 02:54:42 +00:00
committed by zzz
parent 7928ef83cc
commit 01979c08b3
16 changed files with 320 additions and 28 deletions

View File

@@ -238,8 +238,8 @@ public class OrderedProperties extends Properties {
public int compareTo(Object o) {
if (o == null) return -1;
if (o instanceof StringMapEntry) return ((String) getKey()).compareTo(((StringMapEntry) o).getKey());
if (o instanceof String) return ((String) getKey()).compareTo(o);
if (o instanceof StringMapEntry) return ((String) getKey()).compareTo((String)((StringMapEntry) o).getKey());
if (o instanceof String) return ((String) getKey()).compareTo((String)o);
return -2;
}

View File

@@ -15,7 +15,7 @@ import net.i2p.data.DataHelper;
*
*/
public class ReusableGZIPInputStream extends ResettableGZIPInputStream {
private static ArrayList _available = new ArrayList(16);
private static ArrayList _available = new ArrayList(8);
/**
* Pull a cached instance
*/
@@ -36,7 +36,7 @@ public class ReusableGZIPInputStream extends ResettableGZIPInputStream {
*/
public static void release(ReusableGZIPInputStream released) {
synchronized (_available) {
if (_available.size() < 16)
if (_available.size() < 8)
_available.add(released);
}
}