Skip to content

Commit ff68bd0

Browse files
committed
SSLEngineFactory NPE, close AsyncHttpClient#839
1 parent 7e524d9 commit ff68bd0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/com/ning/http/util/SslUtils.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ public static SslUtils getInstance() {
6666
public SSLContext getSSLContext(AsyncHttpClientConfig config) throws GeneralSecurityException {
6767
SSLContext sslContext = config.getSSLContext();
6868

69-
if (sslContext != null) {
69+
if (sslContext == null) {
7070
sslContext = config.isAcceptAnyCertificate() ? looseTrustManagerSSLContext : SSLContext.getDefault();
7171
if (config.getSslSessionCacheSize() != null)
7272
sslContext.getClientSessionContext().setSessionCacheSize(config.getSslSessionCacheSize());

0 commit comments

Comments
 (0)