diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2014-04-21 11:12:50 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2014-04-21 11:12:50 +0000 |
commit | 22b0647e4e088a32e344a01beb996246ec1366be (patch) | |
tree | 4891a0b99cf7ebfcd7554b7d2b7e3038b1e53f17 /lib/libcrypto/bio/bf_lbuf.c | |
parent | d14f7d137c96c708aac796a8523d601e3bed48e7 (diff) |
Bring malloc/calloc/realloc sequences to modern standard
ok guenther
Diffstat (limited to 'lib/libcrypto/bio/bf_lbuf.c')
-rw-r--r-- | lib/libcrypto/bio/bf_lbuf.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libcrypto/bio/bf_lbuf.c b/lib/libcrypto/bio/bf_lbuf.c index 7ed26ccec76..f0bd0d709ea 100644 --- a/lib/libcrypto/bio/bf_lbuf.c +++ b/lib/libcrypto/bio/bf_lbuf.c @@ -106,10 +106,10 @@ linebuffer_new(BIO *bi) { BIO_LINEBUFFER_CTX *ctx; - ctx = (BIO_LINEBUFFER_CTX *)malloc(sizeof(BIO_LINEBUFFER_CTX)); + ctx = malloc(sizeof(BIO_LINEBUFFER_CTX)); if (ctx == NULL) return (0); - ctx->obuf = (char *)malloc(DEFAULT_LINEBUFFER_SIZE); + ctx->obuf = malloc(DEFAULT_LINEBUFFER_SIZE); if (ctx->obuf == NULL) { free(ctx); return (0); @@ -281,7 +281,7 @@ linebuffer_ctrl(BIO *b, int cmd, long num, void *ptr) obs = (int)num; p = ctx->obuf; if ((obs > DEFAULT_LINEBUFFER_SIZE) && (obs != ctx->obuf_size)) { - p = (char *)malloc((int)num); + p = malloc((int)num); if (p == NULL) goto malloc_error; } |