Coverity 1458439: fix resource leak

Reviewed-by: Richard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/11101)
master
Pauli 3 years ago
parent 31b28ad96a
commit 5472821ece

@ -119,6 +119,7 @@ static int rsa_encrypt(void *vprsactx, unsigned char *out, size_t *outlen,
return 0;
}
if (prsactx->oaep_md == NULL) {
OPENSSL_free(tbuf);
prsactx->oaep_md = EVP_MD_fetch(prsactx->libctx, "SHA-1", NULL);
PROVerr(0, ERR_R_INTERNAL_ERROR);
return 0;

Loading…
Cancel
Save