summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbcook <bcook@openbsd.org>2014-07-08 17:44:51 +0000
committerbcook <bcook@openbsd.org>2014-07-08 17:44:51 +0000
commit7840644f2cc66125816def2fb72732509935423c (patch)
treee0402299069f1baf167aac1118cf24ea48ed51bf
parentRepair compilability after the recent uvmexp changes, especially for (diff)
downloadwireguard-openbsd-7840644f2cc66125816def2fb72732509935423c.tar.xz
wireguard-openbsd-7840644f2cc66125816def2fb72732509935423c.zip
remove use of internally-deprecated OPENSSL_malloc/free
ok jsing@
-rw-r--r--regress/lib/libcrypto/ecdh/ecdhtest.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/regress/lib/libcrypto/ecdh/ecdhtest.c b/regress/lib/libcrypto/ecdh/ecdhtest.c
index 620424dbdbf..d6cb61d4609 100644
--- a/regress/lib/libcrypto/ecdh/ecdhtest.c
+++ b/regress/lib/libcrypto/ecdh/ecdhtest.c
@@ -358,7 +358,7 @@ static int ecdh_kat(BIO *out, const char *cname, int nid,
Ztmplen = (EC_GROUP_get_degree(EC_KEY_get0_group(key1)) + 7)/8;
if (Ztmplen != Zlen)
goto err;
- Ztmp = OPENSSL_malloc(Ztmplen);
+ Ztmp = malloc(Ztmplen);
if (!ECDH_compute_key(Ztmp, Ztmplen,
EC_KEY_get0_public_key(key2), key1, 0))
goto err;
@@ -376,8 +376,7 @@ static int ecdh_kat(BIO *out, const char *cname, int nid,
EC_KEY_free(key1);
if (key2)
EC_KEY_free(key2);
- if (Ztmp)
- OPENSSL_free(Ztmp);
+ free(Ztmp);
if (rv)
BIO_puts(out, " ok\n");
else