aboutsummaryrefslogtreecommitdiff
path: root/crypto
diff options
context:
space:
mode:
authorNils Larsch <nils@openssl.org>2007-02-26 18:32:53 +0000
committerNils Larsch <nils@openssl.org>2007-02-26 18:32:53 +0000
commit0d5ac5a738094fb171f01d20375a832e797dab2e (patch)
tree128a4d173ff0e6c529d8c950934b988a81d3059c /crypto
parentc209a358204568b9d0f66f1ceaa6673565b92fad (diff)
downloadopenssl-0d5ac5a738094fb171f01d20375a832e797dab2e.zip
openssl-0d5ac5a738094fb171f01d20375a832e797dab2e.tar.gz
openssl-0d5ac5a738094fb171f01d20375a832e797dab2e.tar.bz2
allow EVP_PKEY_CTX_free(NULL)
Diffstat (limited to 'crypto')
-rw-r--r--crypto/evp/pmeth_lib.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/crypto/evp/pmeth_lib.c b/crypto/evp/pmeth_lib.c
index 5b8000d..500aad9 100644
--- a/crypto/evp/pmeth_lib.c
+++ b/crypto/evp/pmeth_lib.c
@@ -289,6 +289,8 @@ int EVP_PKEY_meth_add0(const EVP_PKEY_METHOD *pmeth)
void EVP_PKEY_CTX_free(EVP_PKEY_CTX *ctx)
{
+ if (ctx == NULL)
+ return;
if (ctx->pmeth && ctx->pmeth->cleanup)
ctx->pmeth->cleanup(ctx);
if (ctx->pkey)