Commit 0c452f28 authored by Hal Finkel's avatar Hal Finkel
Browse files

Rename the pointer argument of crc64_invert for clarity

parent 96316bae
......@@ -84,7 +84,7 @@ uint64_t crc64_omp(const void *input, size_t nbytes);
* Calculate the 'check bytes' for the provided CRC64. If these bytes are
* appended to the original buffer, then the new total CRC64 should be -1.
*/
void crc64_invert(uint64_t cs, void *buffer);
void crc64_invert(uint64_t cs, void *check_bytes);
/*
* Given the CRC64 of the first part of a buffer, and the CRC64 and length of
......
......@@ -1319,8 +1319,8 @@ uint64_t crc64(const void *input, size_t nbytes) {
// Calculate the 'check bytes' for the provided checksum. If these bytes are
// appended to the original buffer, then the new total checksum should be -1.
void crc64_invert(uint64_t cs, void *buffer) {
unsigned char *bytes = (unsigned char *) buffer;
void crc64_invert(uint64_t cs, void *check_bytes) {
unsigned char *bytes = (unsigned char *) check_bytes;
cs ^= UINT64_C(0xffffffffffffffff);
// The CRC is self-inverting (in big-endian, so the bit-reversed CRC is
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment