Fix error path in int create_ssl_ctx_pair()
authorMatt Caswell <matt@openssl.org>
Wed, 13 May 2020 13:45:36 +0000 (14:45 +0100)
committerMatt Caswell <matt@openssl.org>
Fri, 5 Jun 2020 09:31:58 +0000 (10:31 +0100)
commit0d52ede71685e4176999cc5e52000dcb540747fc
tree0f476822894cf2f26b7bc02fdc40b521aff46009
parentb38425393c76ff31560d6b0bdb0b097e7d93ffc4
Fix error path in int create_ssl_ctx_pair()

If we hit the error path and create_ssl_ctx_pair has been passed a
pre-created SSL_CTX then we could end up with a double free.

Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/11834)
test/ssltestlib.c