summaryrefslogtreecommitdiffstats
path: root/crypto/bn/bn_gf2m.c
diff options
context:
space:
mode:
authorRich Salz <rsalz@openssl.org>2015-04-28 15:28:14 -0400
committerRich Salz <rsalz@openssl.org>2015-04-28 15:28:14 -0400
commitb196e7d936fb377d9c5b305748ac25ff0e53ef6d (patch)
treec855f0808899e5e7ef3a704c35f464ca36014964 /crypto/bn/bn_gf2m.c
parent3e47caff4830d2a117eda15b57a5feab89b846ae (diff)
remove malloc casts
Following ANSI C rules, remove the casts from calls to OPENSSL_malloc and OPENSSL_realloc. Reviewed-by: Richard Levitte <levitte@openssl.org>
Diffstat (limited to 'crypto/bn/bn_gf2m.c')
-rw-r--r--crypto/bn/bn_gf2m.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/crypto/bn/bn_gf2m.c b/crypto/bn/bn_gf2m.c
index aeee49a015..fc7ad24296 100644
--- a/crypto/bn/bn_gf2m.c
+++ b/crypto/bn/bn_gf2m.c
@@ -551,7 +551,7 @@ int BN_GF2m_mod_mul(BIGNUM *r, const BIGNUM *a, const BIGNUM *b,
bn_check_top(a);
bn_check_top(b);
bn_check_top(p);
- if ((arr = (int *)OPENSSL_malloc(sizeof(int) * max)) == NULL)
+ if ((arr = OPENSSL_malloc(sizeof(int) * max)) == NULL)
goto err;
ret = BN_GF2m_poly2arr(p, arr, max);
if (!ret || ret > max) {
@@ -610,7 +610,7 @@ int BN_GF2m_mod_sqr(BIGNUM *r, const BIGNUM *a, const BIGNUM *p, BN_CTX *ctx)
bn_check_top(a);
bn_check_top(p);
- if ((arr = (int *)OPENSSL_malloc(sizeof(int) * max)) == NULL)
+ if ((arr = OPENSSL_malloc(sizeof(int) * max)) == NULL)
goto err;
ret = BN_GF2m_poly2arr(p, arr, max);
if (!ret || ret > max) {
@@ -1027,7 +1027,7 @@ int BN_GF2m_mod_exp(BIGNUM *r, const BIGNUM *a, const BIGNUM *b,
bn_check_top(a);
bn_check_top(b);
bn_check_top(p);
- if ((arr = (int *)OPENSSL_malloc(sizeof(int) * max)) == NULL)
+ if ((arr = OPENSSL_malloc(sizeof(int) * max)) == NULL)
goto err;
ret = BN_GF2m_poly2arr(p, arr, max);
if (!ret || ret > max) {
@@ -1087,7 +1087,7 @@ int BN_GF2m_mod_sqrt(BIGNUM *r, const BIGNUM *a, const BIGNUM *p, BN_CTX *ctx)
int *arr = NULL;
bn_check_top(a);
bn_check_top(p);
- if ((arr = (int *)OPENSSL_malloc(sizeof(int) * max)) == NULL)
+ if ((arr = OPENSSL_malloc(sizeof(int) * max)) == NULL)
goto err;
ret = BN_GF2m_poly2arr(p, arr, max);
if (!ret || ret > max) {
@@ -1218,7 +1218,7 @@ int BN_GF2m_mod_solve_quad(BIGNUM *r, const BIGNUM *a, const BIGNUM *p,
int *arr = NULL;
bn_check_top(a);
bn_check_top(p);
- if ((arr = (int *)OPENSSL_malloc(sizeof(int) * max)) == NULL)
+ if ((arr = OPENSSL_malloc(sizeof(int) * max)) == NULL)
goto err;
ret = BN_GF2m_poly2arr(p, arr, max);
if (!ret || ret > max) {