diff options
Diffstat (limited to 'crypto/pem')
-rw-r--r-- | crypto/pem/pem_lib.c | 2 | ||||
-rw-r--r-- | crypto/pem/pem_seal.c | 4 | ||||
-rw-r--r-- | crypto/pem/pem_sign.c | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/crypto/pem/pem_lib.c b/crypto/pem/pem_lib.c index 70e6a70772..431e36804f 100644 --- a/crypto/pem/pem_lib.c +++ b/crypto/pem/pem_lib.c @@ -361,7 +361,7 @@ int PEM_ASN1_write_bio(i2d_of_void *i2d, const char *name, BIO *bp, } /* dzise + 8 bytes are needed */ /* actually it needs the cipher block size extra... */ - data = (unsigned char *)OPENSSL_malloc((unsigned int)dsize + 20); + data = OPENSSL_malloc((unsigned int)dsize + 20); if (data == NULL) { PEMerr(PEM_F_PEM_ASN1_WRITE_BIO, ERR_R_MALLOC_FAILURE); goto err; diff --git a/crypto/pem/pem_seal.c b/crypto/pem/pem_seal.c index e82ab6fe42..374273d14f 100644 --- a/crypto/pem/pem_seal.c +++ b/crypto/pem/pem_seal.c @@ -85,7 +85,7 @@ int PEM_SealInit(PEM_ENCODE_SEAL_CTX *ctx, EVP_CIPHER *type, EVP_MD *md_type, if (j > max) max = j; } - s = (char *)OPENSSL_malloc(max * 2); + s = OPENSSL_malloc(max * 2); if (s == NULL) { PEMerr(PEM_F_PEM_SEALINIT, ERR_R_MALLOC_FAILURE); goto err; @@ -159,7 +159,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 = OPENSSL_malloc(i * 2); if (s == NULL) { PEMerr(PEM_F_PEM_SEALFINAL, ERR_R_MALLOC_FAILURE); goto err; diff --git a/crypto/pem/pem_sign.c b/crypto/pem/pem_sign.c index a3d5c175f9..87cc7273de 100644 --- a/crypto/pem/pem_sign.c +++ b/crypto/pem/pem_sign.c @@ -81,7 +81,7 @@ int PEM_SignFinal(EVP_MD_CTX *ctx, unsigned char *sigret, int i, ret = 0; unsigned int m_len; - m = (unsigned char *)OPENSSL_malloc(EVP_PKEY_size(pkey) + 2); + m = OPENSSL_malloc(EVP_PKEY_size(pkey) + 2); if (m == NULL) { PEMerr(PEM_F_PEM_SIGNFINAL, ERR_R_MALLOC_FAILURE); goto err; |