Skip to content

Commit 7bf4e07

Browse files
committed
SSLEngineFactory NPE, close AsyncHttpClient#839
1 parent 07d2843 commit 7bf4e07

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

api/src/main/java/org/asynchttpclient/util/SslUtils.java

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

72-
if (sslContext != null) {
72+
if (sslContext == null) {
7373
sslContext = config.isAcceptAnyCertificate() ? looseTrustManagerSSLContext : SSLContext.getDefault();
7474
if (config.getSslSessionCacheSize() != null)
7575
sslContext.getClientSessionContext().setSessionCacheSize(config.getSslSessionCacheSize());

0 commit comments

Comments
 (0)