From da414db464cd7393ac8642dd1d285fd8be4a4c2a Mon Sep 17 00:00:00 2001 From: Geoff Thorpe Date: Thu, 20 Apr 2000 07:58:11 +0000 Subject: The handling of DSA_METHOD and DH_METHOD wasn't quite as problematic as with RSA_METHOD (the **_get_default_methods do set the default value if it's not set). However, the code had some duplication and was a bit conter-intuitive. --- crypto/dh/dh_lib.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'crypto/dh') diff --git a/crypto/dh/dh_lib.c b/crypto/dh/dh_lib.c index 6c21463028..be00ceee2f 100644 --- a/crypto/dh/dh_lib.c +++ b/crypto/dh/dh_lib.c @@ -103,9 +103,8 @@ DH *DH_new_method(DH_METHOD *meth) DHerr(DH_F_DH_NEW,ERR_R_MALLOC_FAILURE); return(NULL); } - if(!default_DH_method) default_DH_method = DH_OpenSSL(); if(meth) ret->meth = meth; - else ret->meth = default_DH_method; + else ret->meth = DH_get_default_method(); ret->pad=0; ret->version=0; ret->p=NULL; -- cgit v1.2.3