@@ -133,7 +133,7 @@ void CHAM64::Enc::ProcessAndXorBlock(const byte *inBlock, const byte *xorBlock,
133
133
GetBlock<word16, BigEndian> iblock (inBlock);
134
134
iblock (m_x[0 ])(m_x[1 ])(m_x[2 ])(m_x[3 ]);
135
135
136
- const unsigned int R = 80 ;
136
+ const int R = 80 ;
137
137
for (int i = 0 ; i < R; i+=16 )
138
138
{
139
139
CHAM_EncRound< 0 , 16 >(m_x.begin (), m_rk.begin (), i+0 );
@@ -164,7 +164,7 @@ void CHAM64::Dec::ProcessAndXorBlock(const byte *inBlock, const byte *xorBlock,
164
164
GetBlock<word16, BigEndian> iblock (inBlock);
165
165
iblock (m_x[0 ])(m_x[1 ])(m_x[2 ])(m_x[3 ]);
166
166
167
- const unsigned int R = 80 ;
167
+ const int R = 80 ;
168
168
for (int i = R-1 ; i >=0 ; i-=16 )
169
169
{
170
170
CHAM_DecRound<15 , 16 >(m_x.begin (), m_rk.begin (), i-0 );
@@ -214,7 +214,7 @@ void CHAM128::Enc::ProcessAndXorBlock(const byte *inBlock, const byte *xorBlock,
214
214
{
215
215
case 4 : // 128-bit key
216
216
{
217
- const unsigned int R = 80 ;
217
+ const int R = 80 ;
218
218
for (int i = 0 ; i < R; i+=8 )
219
219
{
220
220
CHAM_EncRound<0 , 8 >(m_x.begin (), m_rk.begin (), i+0 );
@@ -230,7 +230,7 @@ void CHAM128::Enc::ProcessAndXorBlock(const byte *inBlock, const byte *xorBlock,
230
230
}
231
231
case 8 : // 256-bit key
232
232
{
233
- const unsigned int R = 96 ;
233
+ const int R = 96 ;
234
234
for (int i = 0 ; i < R; i+=16 )
235
235
{
236
236
CHAM_EncRound< 0 , 16 >(m_x.begin (), m_rk.begin (), i+0 );
@@ -270,7 +270,7 @@ void CHAM128::Dec::ProcessAndXorBlock(const byte *inBlock, const byte *xorBlock,
270
270
{
271
271
case 4 : // 128-bit key
272
272
{
273
- const unsigned int R = 80 ;
273
+ const int R = 80 ;
274
274
for (int i = R-1 ; i >= 0 ; i-=8 )
275
275
{
276
276
CHAM_DecRound<7 , 8 >(m_x.begin (), m_rk.begin (), i-0 );
@@ -286,7 +286,7 @@ void CHAM128::Dec::ProcessAndXorBlock(const byte *inBlock, const byte *xorBlock,
286
286
}
287
287
case 8 : // 256-bit key
288
288
{
289
- const unsigned int R = 96 ;
289
+ const int R = 96 ;
290
290
for (int i = R-1 ; i >= 0 ; i-=16 )
291
291
{
292
292
CHAM_DecRound<15 , 16 >(m_x.begin (), m_rk.begin (), i-0 );
0 commit comments