X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Futils_crc32.c;h=f9eaf880c03737863741ce3e12bcd3c8f94ab658;hb=edd9af8a874ebc9f2a7f02846807229a648917db;hp=4c6d694160c97f49323f872280f3e1d86b320646;hpb=6299d39b903cb87a3db5b6d2148a2d717754a30a;p=collectd.git diff --git a/src/utils_crc32.c b/src/utils_crc32.c index 4c6d6941..f9eaf880 100644 --- a/src/utils_crc32.c +++ b/src/utils_crc32.c @@ -37,9 +37,10 @@ * polynomial $edb88320 */ -#include +#include +#include -u_int32_t crc32_buffer(const u_char *, size_t); +uint32_t crc32_buffer(const unsigned char *, size_t); static unsigned int crc32_tab[] = { 0x00000000L, 0x77073096L, 0xee0e612cL, 0x990951baL, 0x076dc419L, 0x706af48fL, 0xe963a535L, 0x9e6495a3L, 0x0edb8832L, 0x79dcb8a4L, @@ -97,11 +98,11 @@ static unsigned int crc32_tab[] = { /* Return a 32-bit CRC of the contents of the buffer. */ -u_int32_t -crc32_buffer(const u_char *s, size_t len) +uint32_t +crc32_buffer(const unsigned char *s, size_t len) { size_t i; - u_int32_t ret; + uint32_t ret; ret = 0; for (i = 0; i < len; i++)