diff options
author | Jeffrey Walton <noloader@gmail.com> | 2018-07-05 08:22:59 -0400 |
---|---|---|
committer | Jeffrey Walton <noloader@gmail.com> | 2018-07-05 08:22:59 -0400 |
commit | 665e16d340671e5c36533b0f35f8adfa8e64acb5 (patch) | |
tree | bc4daa30142d3d6e64c1e00f13c7c533ea672ef5 /hc256.cpp | |
parent | fd5dc95f96a08d2397bfef2ce1db6755861aabff (diff) | |
download | cryptopp-git-665e16d340671e5c36533b0f35f8adfa8e64acb5.tar.gz |
Remove unneeded input variable
Diffstat (limited to 'hc256.cpp')
-rw-r--r-- | hc256.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
@@ -34,10 +34,10 @@ inline word32 HC256Policy::H1(word32 u) {
word32 tem;
byte a, b, c, d;
- a = (byte)((u));
- b = (byte)((u) >> 8);
- c = (byte)((u) >> 16);
- d = (byte)((u) >> 24);
+ a = (byte)(u);
+ b = (byte)(u >> 8);
+ c = (byte)(u >> 16);
+ d = (byte)(u >> 24);
tem = m_Q[a] + m_Q[256 + b] + m_Q[512 + c] + m_Q[768 + d];
return (tem);
}
@@ -46,10 +46,10 @@ inline word32 HC256Policy::H2(word32 u) {
word32 tem;
byte a, b, c, d;
- a = (byte)((u));
- b = (byte)((u) >> 8);
- c = (byte)((u) >> 16);
- d = (byte)((u) >> 24);
+ a = (byte)(u);
+ b = (byte)(u >> 8);
+ c = (byte)(u >> 16);
+ d = (byte)(u >> 24);
tem = m_P[a] + m_P[256 + b] + m_P[512 + c] + m_P[768 + d];
return (tem);
}
@@ -95,8 +95,8 @@ void HC256Policy::CipherSetKey(const NameValuePairs ¶ms, const byte *userKey void HC256Policy::OperateKeystream(KeystreamOperation operation, byte *output, const byte *input, size_t iterationCount)
{
size_t msglen = GetBytesPerIteration() * iterationCount;
- const byte* in = input; byte* out = output;
- for (unsigned int i = 0; i < (msglen >> 2); i++, in += 4, out += 4)
+ byte* out = output;
+ for (unsigned int i = 0; i < (msglen >> 2); i++, out += 4)
PutWord(false, LITTLE_ENDIAN_ORDER, out, Generate());
// If AdditiveCipherTemplate does not have an accumulated keystream
|