update some of the static functions

This commit is contained in:
Steffen Jaeckel
2017-06-20 19:58:13 +02:00
parent 8f433f1a36
commit 1bf42ea99a
13 changed files with 72 additions and 72 deletions
+4 -4
View File
@@ -51,7 +51,7 @@ int pelican_init(pelican_state *pelmac, const unsigned char *key, unsigned long
return CRYPT_OK;
}
static void four_rounds(pelican_state *pelmac)
static void _four_rounds(pelican_state *pelmac)
{
ulong32 s0, s1, s2, s3, t0, t1, t2, t3;
int r;
@@ -114,7 +114,7 @@ int pelican_process(pelican_state *pelmac, const unsigned char *in, unsigned lon
for (x = 0; x < 16; x += sizeof(LTC_FAST_TYPE)) {
*(LTC_FAST_TYPE_PTR_CAST((unsigned char *)pelmac->state + x)) ^= *(LTC_FAST_TYPE_PTR_CAST((unsigned char *)in + x));
}
four_rounds(pelmac);
_four_rounds(pelmac);
in += 16;
inlen -= 16;
}
@@ -124,7 +124,7 @@ int pelican_process(pelican_state *pelmac, const unsigned char *in, unsigned lon
while (inlen--) {
pelmac->state[pelmac->buflen++] ^= *in++;
if (pelmac->buflen == 16) {
four_rounds(pelmac);
_four_rounds(pelmac);
pelmac->buflen = 0;
}
}
@@ -148,7 +148,7 @@ int pelican_done(pelican_state *pelmac, unsigned char *out)
}
if (pelmac->buflen == 16) {
four_rounds(pelmac);
_four_rounds(pelmac);
pelmac->buflen = 0;
}
pelmac->state[pelmac->buflen++] ^= 0x80;