23-Jun megacz Box.java: JPEG hack, fastpath rendering bugfix,
fixedaspect, improved >500 Pos/SizeChange loop breakout
+23-Jun megacz HTTP.java: removed System.out.println()
+
if (port == -1) port = ssl ? 443 : 80;
host = this.url.getHost();
if (Log.on) Log.log(this, "creating HTTP object for connection to " + host + ":" + port);
- addHeader("Host", host); // host header is always sent verbatim
+ addHeader("Host", host); // host header is always sent verbatim
if (!skipResolveCheck) host = resolveAndCheckIfFirewalled(host); // might have to use the strict IP if behind a proxy
ProxyInfo pi = Platform.detectProxy();
if (sock == null && pi != null && pi.socksProxyHost != null) sock = attemptSocksProxy(pi.socksProxyHost, pi.socksProxyPort);
if (sock == null) sock = attemptDirect();
if (sock == null) throw new HTTPException("all socket creation attempts have failed");
- sock.setTcpNoDelay(true);
}
} else {
PrintWriter pw = new PrintWriter(new OutputStreamWriter(sock.getOutputStream()));
pw.print("GET " + path + " HTTP/1.0\r\n");
- System.out.print("GET " + path + " HTTP/1.0\r\n");
pw.print("User-Agent: XWT\r\n");
pw.print(headers);
pw.print("\r\n");
in = new BufferedInputStream(sock.getInputStream());
// we can't use a BufferedReader directly on the input stream,
- // since it will buffer beyond the end of the headers
+ // since it will buffer past the end of the headers
byte[] buf = new byte[4096];
int buflen = 0;
while(true) {