summaryrefslogtreecommitdiffstats
path: root/crypto/evp/p_lib.c
diff options
context:
space:
mode:
authorDr. Stephen Henson <steve@openssl.org>2009-11-12 19:24:34 +0000
committerDr. Stephen Henson <steve@openssl.org>2009-11-12 19:24:34 +0000
commit9b2cfb890c39df791a5c6ade81d08b9885e1a0c4 (patch)
tree102d76bb8771915a80650fa6526ef19270bd5f8a /crypto/evp/p_lib.c
parentb2f364ec6228a2d98db44491d8a3dd44908c8709 (diff)
set engine to NULL after releasing it
Diffstat (limited to 'crypto/evp/p_lib.c')
-rw-r--r--crypto/evp/p_lib.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/crypto/evp/p_lib.c b/crypto/evp/p_lib.c
index 249ac2bd2a..1916c61699 100644
--- a/crypto/evp/p_lib.c
+++ b/crypto/evp/p_lib.c
@@ -220,7 +220,10 @@ static int pkey_set_type(EVP_PKEY *pkey, int type, const char *str, int len)
#ifndef OPENSSL_NO_ENGINE
/* If we have an ENGINE release it */
if (pkey->engine)
+ {
ENGINE_finish(pkey->engine);
+ pkey->engine = NULL;
+ }
#endif
}
if (str)