From: Pauli Date: Sun, 16 Feb 2020 07:58:45 +0000 (+1000) Subject: Coverity 1458439: fix resource leak X-Git-Tag: openssl-3.0.0-alpha1~453 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=5472821ece34c87148271abd649538da0743df40;p=oweals%2Fopenssl.git Coverity 1458439: fix resource leak Reviewed-by: Richard Levitte (Merged from https://github.com/openssl/openssl/pull/11101) --- diff --git a/providers/implementations/asymciphers/rsa_enc.c b/providers/implementations/asymciphers/rsa_enc.c index 2cce8474cd..87349ed64b 100644 --- a/providers/implementations/asymciphers/rsa_enc.c +++ b/providers/implementations/asymciphers/rsa_enc.c @@ -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;