Skip to content

Commit

Permalink
msvc compiler errors.
Browse files Browse the repository at this point in the history
  • Loading branch information
JonathanHenson committed Jan 24, 2024
1 parent bfb8600 commit 86ca022
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion tests/crc64_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
static const uint64_t POLY_CRC64XZ = 0xc96c5795d7870f42;

// Any input with the CRC of that input appended should produce this CRC value. (Note: inverting the bits)
static const uint64_t RESIDUE_CRC64XZ = ~0x49958c9abd7d353f;
static const uint64_t RESIDUE_CRC64XZ = (uint64_t)~0x49958c9abd7d353f;

static const uint8_t DATA_32_ZEROS[32] = {0};
static const uint64_t KNOWN_CRC64XZ_32_ZEROES = 0xC95AF8617CD5330C;
Expand Down
2 changes: 1 addition & 1 deletion tests/crc_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ static int s_test_known_crc_32(
ASSERT_HEX_EQUALS(expected_crc, result, "%s(%s)", func_name, data_name);

// Compute the residue of the buffer (the CRC of the buffer plus its CRC) - will always be a constant value
uint32_t residue = func((const uint8_t *)&result, 4, result); // assuming little endian
uint32_t residue = (uint32_t)func((const uint8_t *)&result, 4, result); // assuming little endian
ASSERT_HEX_EQUALS(expected_residue, residue, "len %d residue %s(%s)", length, func_name, data_name);

// chain the crc computation so 2 calls each operate on about 1/2 of the buffer
Expand Down

0 comments on commit 86ca022

Please sign in to comment.