diff options
author | Vicent Marti <tanoku@gmail.com> | 2016-06-06 11:50:13 +0200 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2016-06-06 15:39:06 -0700 |
commit | d4cb8e767ce224d31501c19fb11a220824df9bf8 (patch) | |
tree | 8eb23c4bfd277c41bcc9de0360a3e38439a52d18 /src/buffer.c | |
parent | f4264ac96e88ec32cd0d63641207bddcfd6f8ce1 (diff) |
msvc: Fix warnings and errors
Diffstat (limited to 'src/buffer.c')
-rw-r--r-- | src/buffer.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/buffer.c b/src/buffer.c index e191056..b3e9811 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -50,7 +50,8 @@ void cmark_strbuf_grow(cmark_strbuf *buf, bufsize_t target_size) { new_size += 1; new_size = (new_size + 7) & ~7; - buf->ptr = buf->mem->realloc(buf->asize ? buf->ptr : NULL, new_size); + buf->ptr = (unsigned char *)buf->mem->realloc( + buf->asize ? buf->ptr : NULL, new_size); buf->asize = new_size; } @@ -146,7 +147,7 @@ unsigned char *cmark_strbuf_detach(cmark_strbuf *buf) { if (buf->asize == 0) { /* return an empty string */ - return buf->mem->calloc(1, 1); + return (unsigned char *)buf->mem->calloc(1, 1); } cmark_strbuf_init(buf->mem, buf, 0); |