Otherwise ssl3_cipher() cannot work properly.
Fixes Coverity CID
1509401
Reviewed-by: Paul Dale <pauli@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/19027)
return 0;
ds = rl->enc_ctx;
- if (rl->enc_ctx == NULL)
- enc = NULL;
- else
- enc = EVP_CIPHER_CTX_get0_cipher(rl->enc_ctx);
+ if (ds == NULL || (enc = EVP_CIPHER_CTX_get0_cipher(ds)) == NULL)
+ return 0;
provided = (EVP_CIPHER_get0_provider(enc) != NULL);