Skip to content

Commit 05fba68

Browse files
committed
Use existing session context if new is actually NULL
1 parent 75a3e8b commit 05fba68

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

ssl/ssl_lib.cc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2856,7 +2856,8 @@ SSL_CTX *SSL_set_SSL_CTX(SSL *ssl, SSL_CTX *ctx) {
28562856
if (!ssl->config) {
28572857
return NULL;
28582858
}
2859-
if (ssl->ctx.get() == ctx) {
2859+
2860+
if (!ctx || ssl->ctx.get() == ctx) {
28602861
return ssl->ctx.get();
28612862
}
28622863

0 commit comments

Comments
 (0)