From: Pauli Date: Sun, 28 Jun 2020 22:17:25 +0000 (+1000) Subject: coverity: CID 1464987: USE AFTER FREE X-Git-Tag: openssl-3.0.0-alpha5~94 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c4d02214053d34990ce28598691f3dddef6f3868;p=thirdparty%2Fopenssl.git coverity: CID 1464987: USE AFTER FREE Reviewed-by: Tim Hudson (Merged from https://github.com/openssl/openssl/pull/12309) --- diff --git a/providers/implementations/rands/drbg.c b/providers/implementations/rands/drbg.c index c2fa99b865c..3394271835f 100644 --- a/providers/implementations/rands/drbg.c +++ b/providers/implementations/rands/drbg.c @@ -503,7 +503,7 @@ int PROV_DRBG_instantiate(PROV_DRBG *drbg, unsigned int strength, drbg->min_noncelen, drbg->max_noncelen)) { PROVerr(0, PROV_R_ERROR_RETRIEVING_NONCE); - OPENSSL_free(nonce); + goto end; } #ifndef PROV_RAND_GET_RANDOM_NONCE } else if (drbg->parent != NULL) {