Use blockSize throughout HashMultipleBlocks

This commit is contained in:
Jeffrey Walton 2018-07-20 20:28:07 -04:00
parent 414c5c5438
commit aeaa4f623f
No known key found for this signature in database
GPG Key ID: B36AB348921B1838

View File

@ -110,7 +110,7 @@ template <class T, class BASE> size_t IteratedHashBase<T, BASE>::HashMultipleBlo
}
else
{
std::memcpy(dataBuf, input, this->BlockSize());
std::memcpy(dataBuf, input, blockSize);
this->HashEndianCorrectedBlock(dataBuf);
}
}
@ -118,13 +118,13 @@ template <class T, class BASE> size_t IteratedHashBase<T, BASE>::HashMultipleBlo
{
if (IsAligned<word64>(input))
{
ByteReverse(dataBuf, input, this->BlockSize());
ByteReverse(dataBuf, input, blockSize);
this->HashEndianCorrectedBlock(dataBuf);
}
else
{
std::memcpy(dataBuf, input, this->BlockSize());
ByteReverse(dataBuf, dataBuf, this->BlockSize());
std::memcpy(dataBuf, input, blockSize);
ByteReverse(dataBuf, dataBuf, blockSize);
this->HashEndianCorrectedBlock(dataBuf);
}
}