From: Eric Dequin Date: Thu, 12 Feb 2015 15:44:30 +0000 (-0500) Subject: Missing OPENSSL_free on error path. X-Git-Tag: OpenSSL_1_0_1m~64 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=a1331af032ff038a8e2a111c54f7d0722a0f7a49;p=oweals%2Fopenssl.git Missing OPENSSL_free on error path. Reviewed-by: Andy Polyakov Reviewed-by: Richard Levitte (cherry picked from commit 1d2932de4cefcc200f175863a42c311916269981) --- diff --git a/ssl/t1_enc.c b/ssl/t1_enc.c index 99d830d449..741dc0b6b4 100644 --- a/ssl/t1_enc.c +++ b/ssl/t1_enc.c @@ -631,6 +631,7 @@ int tls1_setup_key_block(SSL *s) if ((p2 = (unsigned char *)OPENSSL_malloc(num)) == NULL) { SSLerr(SSL_F_TLS1_SETUP_KEY_BLOCK, ERR_R_MALLOC_FAILURE); + OPENSSL_free(p1); goto err; } #ifdef TLS_DEBUG