summaryrefslogtreecommitdiffstats
path: root/src/crc.c
diff options
context:
space:
mode:
authorChristophe Grenier <grenier@cgsecurity.org>2008-06-23 19:28:58 +0200
committerChristophe Grenier <grenier@cgsecurity.org>2008-06-23 19:28:58 +0200
commitb849a82750086bdddd127c7d43dd0a7381b3c28e (patch)
treeb7d0fd90e7e93e34455f0c582b2193803bbce4e1 /src/crc.c
parent50a0862d48da7f0260524b17c3b33281a1b5dcc7 (diff)
Make the code less C++ hostile
Diffstat (limited to 'src/crc.c')
-rw-r--r--src/crc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/crc.c b/src/crc.c
index c005103..b1faa6c 100644
--- a/src/crc.c
+++ b/src/crc.c
@@ -89,7 +89,7 @@ unsigned int get_crc32(const void*buf, const unsigned int len, const uint32_t se
{
unsigned int i;
register uint32_t crc32val;
- const unsigned char *s=buf;
+ const unsigned char *s=(const unsigned char *)buf;
crc32val = seed;
for (i = 0; i < len; i ++)
{
@@ -102,7 +102,7 @@ unsigned int get_crc32(const void*buf, const unsigned int len, const uint32_t se
uint32_t* make_crc32_table(uint32_t poly)
{
unsigned i,j;
- uint32_t *crctable = MALLOC(256*sizeof(uint32_t));
+ uint32_t *crctable = (uint32_t *)MALLOC(256*sizeof(uint32_t));
for (i=0;i<256;i++)
{
uint32_t r=i;