Fix a memory leak in the speed app

Make sure we free the ecdsa_key object after we have finished using it.

Reviewed-by: Neil Horman <nhorman@openssl.org>
Reviewed-by: Tom Cosgrove <tom.cosgrove@arm.com>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/25153)
This commit is contained in:
Matt Caswell 2024-08-12 09:04:19 +01:00 committed by Tomas Mraz
parent 509022ddf8
commit 8e82304adb

View File

@ -3266,6 +3266,7 @@ int speed_main(int argc, char **argv)
/* if longer than 10s, don't do any more */
stop_it(ecdsa_doit, testnum);
}
EVP_PKEY_free(ecdsa_key);
}
for (testnum = 0; testnum < EC_NUM; testnum++) {