Update okhttp to 4.9

This commit is contained in:
NekoInverter committed 2020-12-19 15:56:59 +08:00
1 parent 466f8a9fd7
commit 883205a7ff
2 files changed
+14 -3

No files matched your search

@@ -29,7 +29,8 @@ public class EhSSLSocketFactory extends SSLSocketFactory {
return ((SSLSocketFactory) getDefault()).createSocket(s, host, port, autoClose);
}
InetAddress address = s.getInetAddress();
if (autoClose) s.close();
// okhttp 4.9 don't like this
//if (autoClose) s.close();
SSLSocket socket = (SSLSocket) getDefault().createSocket(address, port);
SSLSession sslSession = socket.getSession();
Log.d("EhSSLSocketFactory", "Host: " + host + " Address: " + address.getHostAddress() + " Protocol:" + sslSession.getProtocol() + " CipherSuite:" + sslSession.getCipherSuite());