summaryrefslogtreecommitdiff
path: root/lib/libcrypto/pem/pem_seal.c
diff options
context:
space:
mode:
authorBob Beck <beck@cvs.openbsd.org>2014-04-17 13:37:51 +0000
committerBob Beck <beck@cvs.openbsd.org>2014-04-17 13:37:51 +0000
commit798a6f0972ce4f8ea25aa987dc43e626dc6d4087 (patch)
tree557371c7b1514332c466ec6233d3e6af96c88520 /lib/libcrypto/pem/pem_seal.c
parenteea79ffdb77e3dd4cdbd3f98ed1b44d9522496fa (diff)
Change library to use intrinsic memory allocation functions instead of
OPENSSL_foo wrappers. This changes: OPENSSL_malloc->malloc OPENSSL_free->free OPENSSL_relloc->realloc OPENSSL_freeFunc->free
Diffstat (limited to 'lib/libcrypto/pem/pem_seal.c')
-rw-r--r--lib/libcrypto/pem/pem_seal.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/libcrypto/pem/pem_seal.c b/lib/libcrypto/pem/pem_seal.c
index b6b4e13498e..bac7b16b441 100644
--- a/lib/libcrypto/pem/pem_seal.c
+++ b/lib/libcrypto/pem/pem_seal.c
@@ -86,7 +86,7 @@ int PEM_SealInit(PEM_ENCODE_SEAL_CTX *ctx, EVP_CIPHER *type, EVP_MD *md_type,
j=RSA_size(pubk[i]->pkey.rsa);
if (j > max) max=j;
}
- s=(char *)OPENSSL_malloc(max*2);
+ s=(char *)malloc(max*2);
if (s == NULL)
{
PEMerr(PEM_F_PEM_SEALINIT,ERR_R_MALLOC_FAILURE);
@@ -114,7 +114,7 @@ int PEM_SealInit(PEM_ENCODE_SEAL_CTX *ctx, EVP_CIPHER *type, EVP_MD *md_type,
ret=npubk;
err:
- if (s != NULL) OPENSSL_free(s);
+ if (s != NULL) free(s);
OPENSSL_cleanse(key,EVP_MAX_KEY_LENGTH);
return(ret);
}
@@ -157,7 +157,7 @@ int PEM_SealFinal(PEM_ENCODE_SEAL_CTX *ctx, unsigned char *sig, int *sigl,
}
i=RSA_size(priv->pkey.rsa);
if (i < 100) i=100;
- s=(unsigned char *)OPENSSL_malloc(i*2);
+ s=(unsigned char *)malloc(i*2);
if (s == NULL)
{
PEMerr(PEM_F_PEM_SEALFINAL,ERR_R_MALLOC_FAILURE);
@@ -179,7 +179,7 @@ int PEM_SealFinal(PEM_ENCODE_SEAL_CTX *ctx, unsigned char *sig, int *sigl,
err:
EVP_MD_CTX_cleanup(&ctx->md);
EVP_CIPHER_CTX_cleanup(&ctx->cipher);
- if (s != NULL) OPENSSL_free(s);
+ if (s != NULL) free(s);
return(ret);
}
#else /* !OPENSSL_NO_RSA */