Skip to content

Commit 9ee34ec

Browse files
pablodelaratkanteck
authored andcommitted
crc: use macro to print 64-bit value
Signed-off-by: Pablo de Lara <[email protected]>
1 parent cf967e5 commit 9ee34ec

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

crc/crc64_example.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
**********************************************************************/
2929
#include <stdio.h>
3030
#include <stdlib.h>
31+
#include <inttypes.h>
3132
#include <assert.h>
3233
#include "crc64.h"
3334

@@ -62,7 +63,8 @@ int main(int argc, char *argv[])
6263
}
6364

6465
fclose(in);
65-
printf("total length is %ld, checksum is 0x%lx\n", total_in, crc64_checksum);
66+
printf("total length is %" PRIu64 ", checksum is 0x%" PRIx64 "\n", total_in,
67+
crc64_checksum);
6668

6769
return 0;
6870
}

0 commit comments

Comments
 (0)