summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/lib/libcrypto/ecdsa/ecs_ossl.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/libcrypto/ecdsa/ecs_ossl.c b/src/lib/libcrypto/ecdsa/ecs_ossl.c
index adbabb609b..514de21c0c 100644
--- a/src/lib/libcrypto/ecdsa/ecs_ossl.c
+++ b/src/lib/libcrypto/ecdsa/ecs_ossl.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: ecs_ossl.c,v 1.45 2023/07/02 13:37:09 tb Exp $ */ 1/* $OpenBSD: ecs_ossl.c,v 1.46 2023/07/03 05:29:03 tb Exp $ */
2/* 2/*
3 * Written by Nils Larsch for the OpenSSL project 3 * Written by Nils Larsch for the OpenSSL project
4 */ 4 */
@@ -104,9 +104,8 @@ ossl_ecdsa_sign(int type, const unsigned char *dgst, int dlen, unsigned char *si
104 int outlen = 0; 104 int outlen = 0;
105 int ret = 0; 105 int ret = 0;
106 106
107 if ((s = ECDSA_do_sign_ex(dgst, dlen, kinv, r, eckey)) == NULL) { 107 if ((s = ECDSA_do_sign_ex(dgst, dlen, kinv, r, eckey)) == NULL)
108 goto err; 108 goto err;
109 }
110 if ((outlen = i2d_ECDSA_SIG(s, &sig)) < 0) { 109 if ((outlen = i2d_ECDSA_SIG(s, &sig)) < 0) {
111 outlen = 0; 110 outlen = 0;
112 goto err; 111 goto err;
@@ -117,6 +116,7 @@ ossl_ecdsa_sign(int type, const unsigned char *dgst, int dlen, unsigned char *si
117 err: 116 err:
118 *siglen = outlen; 117 *siglen = outlen;
119 ECDSA_SIG_free(s); 118 ECDSA_SIG_free(s);
119
120 return ret; 120 return ret;
121} 121}
122 122