From: Matt Caswell Date: Wed, 9 Mar 2016 01:07:26 +0000 (+0000) Subject: Remove another lock from e_chil X-Git-Tag: OpenSSL_1_1_0-pre4~195 X-Git-Url: https://git.openssl.org/gitweb/?p=openssl.git;a=commitdiff_plain;h=af48aa7197cbaf9e18eede5861182c0a6b2761c1 Remove another lock from e_chil Reviewed-by: Richard Levitte --- diff --git a/engines/e_chil.c b/engines/e_chil.c index c6ae800069..a748e59686 100644 --- a/engines/e_chil.c +++ b/engines/e_chil.c @@ -870,14 +870,14 @@ static EVP_PKEY *hwcrhk_load_pubkey(ENGINE *eng, const char *key_id, { RSA *rsa = NULL; - CRYPTO_w_lock(CRYPTO_LOCK_EVP_PKEY); + CRYPTO_THREAD_write_lock(chil_lock); rsa = res->pkey.rsa; res->pkey.rsa = RSA_new(); res->pkey.rsa->n = rsa->n; res->pkey.rsa->e = rsa->e; rsa->n = NULL; rsa->e = NULL; - CRYPTO_w_unlock(CRYPTO_LOCK_EVP_PKEY); + CRYPTO_THREAD_unlock(chil_lock); RSA_free(rsa); } break;