if the function table entry already exists when _init() is called, don't
overwrite it.
This commit is contained in:
@@ -16,7 +16,7 @@
|
||||
*/
|
||||
|
||||
/*
|
||||
* $Id: gssapi_link.c,v 1.8 2001/11/06 20:47:54 bwelling Exp $
|
||||
* $Id: gssapi_link.c,v 1.9 2001/11/06 22:50:55 bwelling Exp $
|
||||
*/
|
||||
|
||||
#ifdef GSSAPI
|
||||
@@ -209,8 +209,9 @@ static dst_func_t gssapi_functions = {
|
||||
|
||||
isc_result_t
|
||||
dst__gssapi_init(dst_func_t **funcp) {
|
||||
REQUIRE(funcp != NULL && *funcp == NULL);
|
||||
*funcp = &gssapi_functions;
|
||||
REQUIRE(funcp != NULL);
|
||||
if (*funcp == NULL)
|
||||
*funcp = &gssapi_functions;
|
||||
return (ISC_R_SUCCESS);
|
||||
}
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
/*
|
||||
* Principal Author: Brian Wellington
|
||||
* $Id: hmac_link.c,v 1.55 2001/11/06 20:47:55 bwelling Exp $
|
||||
* $Id: hmac_link.c,v 1.56 2001/11/06 22:50:56 bwelling Exp $
|
||||
*/
|
||||
|
||||
#include <config.h>
|
||||
@@ -277,7 +277,8 @@ static dst_func_t hmacmd5_functions = {
|
||||
|
||||
isc_result_t
|
||||
dst__hmacmd5_init(dst_func_t **funcp) {
|
||||
REQUIRE(funcp != NULL && *funcp == NULL);
|
||||
*funcp = &hmacmd5_functions;
|
||||
REQUIRE(funcp != NULL);
|
||||
if (*funcp == NULL)
|
||||
*funcp = &hmacmd5_functions;
|
||||
return (ISC_R_SUCCESS);
|
||||
}
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
/*
|
||||
* Principal Author: Brian Wellington
|
||||
* $Id: openssldh_link.c,v 1.40 2001/11/06 20:47:57 bwelling Exp $
|
||||
* $Id: openssldh_link.c,v 1.41 2001/11/06 22:50:57 bwelling Exp $
|
||||
*/
|
||||
|
||||
#ifdef OPENSSL
|
||||
@@ -536,14 +536,16 @@ static dst_func_t openssldh_functions = {
|
||||
|
||||
isc_result_t
|
||||
dst__openssldh_init(dst_func_t **funcp) {
|
||||
REQUIRE(funcp != NULL && *funcp == NULL);
|
||||
BN_init(&bn2);
|
||||
BN_init(&bn768);
|
||||
BN_init(&bn1024);
|
||||
BN_set_word(&bn2, 2);
|
||||
BN_fromhex(&bn768, PRIME768);
|
||||
BN_fromhex(&bn1024, PRIME1024);
|
||||
*funcp = &openssldh_functions;
|
||||
REQUIRE(funcp != NULL);
|
||||
if (*funcp == NULL) {
|
||||
BN_init(&bn2);
|
||||
BN_init(&bn768);
|
||||
BN_init(&bn1024);
|
||||
BN_set_word(&bn2, 2);
|
||||
BN_fromhex(&bn768, PRIME768);
|
||||
BN_fromhex(&bn1024, PRIME1024);
|
||||
*funcp = &openssldh_functions;
|
||||
}
|
||||
return (ISC_R_SUCCESS);
|
||||
}
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
* PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: openssldsa_link.c,v 1.6 2001/11/06 20:47:58 bwelling Exp $ */
|
||||
/* $Id: openssldsa_link.c,v 1.7 2001/11/06 22:51:00 bwelling Exp $ */
|
||||
|
||||
#ifdef OPENSSL
|
||||
|
||||
@@ -429,8 +429,9 @@ static dst_func_t openssldsa_functions = {
|
||||
|
||||
isc_result_t
|
||||
dst__openssldsa_init(dst_func_t **funcp) {
|
||||
REQUIRE(funcp != NULL && *funcp == NULL);
|
||||
*funcp = &openssldsa_functions;
|
||||
REQUIRE(funcp != NULL);
|
||||
if (*funcp == NULL)
|
||||
*funcp = &openssldsa_functions;
|
||||
return (ISC_R_SUCCESS);
|
||||
}
|
||||
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
|
||||
/*
|
||||
* Principal Author: Brian Wellington
|
||||
* $Id: opensslrsa_link.c,v 1.15 2001/11/06 20:47:59 bwelling Exp $
|
||||
* $Id: opensslrsa_link.c,v 1.16 2001/11/06 22:50:58 bwelling Exp $
|
||||
*/
|
||||
#ifdef OPENSSL
|
||||
|
||||
@@ -512,8 +512,9 @@ static dst_func_t opensslrsa_functions = {
|
||||
|
||||
isc_result_t
|
||||
dst__opensslrsa_init(dst_func_t **funcp) {
|
||||
REQUIRE(funcp != NULL && *funcp == NULL);
|
||||
*funcp = &opensslrsa_functions;
|
||||
REQUIRE(funcp != NULL);
|
||||
if (*funcp == NULL)
|
||||
*funcp = &opensslrsa_functions;
|
||||
return (ISC_R_SUCCESS);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user