Commit 6b3fdb21 authored by Thomas Jahns's avatar Thomas Jahns 🤸
Browse files

Fix implicit type conversions in checksum call.

parent c4d2ecbf
......@@ -11,7 +11,7 @@ uint32_t cdiCheckSum(int type, int count, void *buffer)
uint32_t s = 0U;
xassert(count >= 0);
size_t elemSize = (size_t)serializeGetSizeInCore(1, type, NULL);
memcrc_r_eswap(&s, (const unsigned char*) buffer, count, elemSize);
s = memcrc_finish(&s, elemSize * (size_t)count);
memcrc_r_eswap(&s, (const unsigned char *)buffer, (size_t)count, elemSize);
s = memcrc_finish(&s, (off_t)(elemSize * (size_t)count));
return s;
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