diff options
Diffstat (limited to 'apps')
-rw-r--r-- | apps/ec.c | 3 | ||||
-rw-r--r-- | apps/ecparam.c | 3 | ||||
-rw-r--r-- | apps/speed.c | 9 |
3 files changed, 5 insertions, 10 deletions
@@ -345,8 +345,7 @@ int MAIN(int argc, char **argv) end: BIO_free(in); BIO_free_all(out); - if (eckey) - EC_KEY_free(eckey); + EC_KEY_free(eckey); if (passin) OPENSSL_free(passin); if (passout) diff --git a/apps/ecparam.c b/apps/ecparam.c index d4177474d5..c6a175146c 100644 --- a/apps/ecparam.c +++ b/apps/ecparam.c @@ -623,8 +623,7 @@ int MAIN(int argc, char **argv) OPENSSL_free(buffer); BIO_free(in); BIO_free_all(out); - if (group != NULL) - EC_GROUP_free(group); + EC_GROUP_free(group); apps_shutdown(); OPENSSL_EXIT(ret); } diff --git a/apps/speed.c b/apps/speed.c index d2034a4898..df972a3b90 100644 --- a/apps/speed.c +++ b/apps/speed.c @@ -2457,13 +2457,10 @@ int MAIN(int argc, char **argv) #ifndef OPENSSL_NO_EC for (i = 0; i < EC_NUM; i++) - if (ecdsa[i] != NULL) - EC_KEY_free(ecdsa[i]); + EC_KEY_free(ecdsa[i]); for (i = 0; i < EC_NUM; i++) { - if (ecdh_a[i] != NULL) - EC_KEY_free(ecdh_a[i]); - if (ecdh_b[i] != NULL) - EC_KEY_free(ecdh_b[i]); + EC_KEY_free(ecdh_a[i]); + EC_KEY_free(ecdh_b[i]); } #endif |