From f3052a9eee9642fbd90486e5edbf0af99c6e960b Mon Sep 17 00:00:00 2001 From: Richard Levitte Date: Wed, 5 Jul 2000 16:00:18 +0000 Subject: [PATCH] Don't initialise the pointers to mutex functions directly in the structure. This is correctly taken care of by hwcrhk_init(). While we're at it, give this engine the official name of the library used (CHIL, for Cryptographic Hardware Interface Library). --- crypto/engine/hw_ncipher.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/crypto/engine/hw_ncipher.c b/crypto/engine/hw_ncipher.c index 1a0c41ef10..05a75dfc16 100644 --- a/crypto/engine/hw_ncipher.c +++ b/crypto/engine/hw_ncipher.c @@ -155,7 +155,7 @@ static RAND_METHOD hwcrhk_rand = /* Our ENGINE structure. */ static ENGINE engine_hwcrhk = { - "hwcrhk", + "chil", "nCipher hardware engine support", &hwcrhk_rsa, NULL, @@ -233,14 +233,16 @@ static HWCryptoHook_InitInfo hwcrhk_globals = { 0, /* Max simultaneous, 0 = default */ /* The next few are mutex stuff: we write wrapper functions - round the OS mutex functions. - Currently, the support in OpenSSL is just not good enough, - so this part is currently skipped, but worked on. */ + around the OS mutex functions. We initialise them to 0 + here, and change that to actual function pointers in hwcrhk_init() + if dynamic locks are support (that is, if the application + programmer has made sure of setting up callbacks bafore starting + this engine). */ sizeof(HWCryptoHook_Mutex), - hwcrhk_mutex_init, - hwcrhk_mutex_lock, - hwcrhk_mutex_unlock, - hwcrhk_mutex_destroy, + 0, + 0, + 0, + 0, /* The next few are condvar stuff: we write wrapper functions round the OS functions. Currently not implemented and not -- 2.25.1