From: Dmitry Belyavskiy Date: Tue, 13 Dec 2016 18:12:22 +0000 (+0300) Subject: Erroneous check removed X-Git-Tag: v1.1.0.2~15 X-Git-Url: http://wagner.pp.ru/gitweb/?a=commitdiff_plain;h=cf50e3aee85c81690a541314541b0a31149004e9;p=openssl-gost%2Fengine.git Erroneous check removed --- diff --git a/gost_ameth.c b/gost_ameth.c index 34f6f81..66f89a5 100644 --- a/gost_ameth.c +++ b/gost_ameth.c @@ -707,11 +707,11 @@ static int pub_encode_gost_ec(X509_PUBKEY *pub, const EVP_PKEY *pk) int ptype = V_ASN1_UNDEF; algobj = OBJ_nid2obj(EVP_PKEY_base_id(pk)); - if (EVP_PKEY_save_parameters((EVP_PKEY *)pk, -1)) { - ASN1_STRING *params = encode_gost_algor_params(pk); - pval = params; - ptype = V_ASN1_SEQUENCE; - } + + ASN1_STRING *params = encode_gost_algor_params(pk); + pval = params; + ptype = V_ASN1_SEQUENCE; + order = BN_new(); if (!order) { GOSTerr(GOST_F_PUB_ENCODE_GOST_EC, ERR_R_MALLOC_FAILURE);