Switch to size_t datatype

pull/681/head^2
Jeffrey Walton 2018-07-05 10:42:55 -04:00
parent c9c51a5e01
commit 717a81484a
No known key found for this signature in database
GPG Key ID: B36AB348921B1838
2 changed files with 2 additions and 2 deletions

View File

@ -96,7 +96,7 @@ void HC256Policy::OperateKeystream(KeystreamOperation operation, byte *output, c
{ {
size_t msglen = GetBytesPerIteration() * iterationCount; size_t msglen = GetBytesPerIteration() * iterationCount;
byte* out = output; byte* out = output;
for (unsigned int i = 0; i < (msglen >> 2); i++, out += 4) for (size_t i = 0; i < (msglen >> 2); i++, out += 4)
PutWord(false, LITTLE_ENDIAN_ORDER, out, Generate()); PutWord(false, LITTLE_ENDIAN_ORDER, out, Generate());
// If AdditiveCipherTemplate does not have an accumulated keystream // If AdditiveCipherTemplate does not have an accumulated keystream

View File

@ -124,7 +124,7 @@ void RabbitPolicy::CipherSetKey(const NameValuePairs &params, const byte *userKe
void RabbitPolicy::OperateKeystream(KeystreamOperation operation, byte *output, const byte *input, size_t iterationCount) void RabbitPolicy::OperateKeystream(KeystreamOperation operation, byte *output, const byte *input, size_t iterationCount)
{ {
byte* out = output; byte* out = output;
for (unsigned int i = 0; i<iterationCount; ++i, out += 16) for (size_t i = 0; i<iterationCount; ++i, out += 16)
{ {
/* Iterate the system */ /* Iterate the system */
m_wcy = NextState(m_wc, m_wx, m_wcy); m_wcy = NextState(m_wc, m_wx, m_wcy);