Explicitly cast len to unsigned long for %lu
This commit is contained in:
parent
60731fb6e8
commit
c1c367c1bd
2
cksum.c
2
cksum.c
|
@ -100,7 +100,7 @@ cksum(int fd, const char *s)
|
||||||
for(i = len; i > 0; i >>= 8)
|
for(i = len; i > 0; i >>= 8)
|
||||||
ck = (ck << 8) ^ crctab[(ck >> 24) ^ (i & 0xFF)];
|
ck = (ck << 8) ^ crctab[(ck >> 24) ^ (i & 0xFF)];
|
||||||
|
|
||||||
printf("%u %lu", ~ck, len);
|
printf("%u %lu", ~ck, (unsigned long)len);
|
||||||
if(s != NULL)
|
if(s != NULL)
|
||||||
printf(" %s", s);
|
printf(" %s", s);
|
||||||
putchar('\n');
|
putchar('\n');
|
||||||
|
|
Loading…
Reference in New Issue
Block a user