the comment FALLTHROUGH is common for several lint tool
This commit is contained in:
parent
c22acc2d07
commit
9749958fe5
@ -96,9 +96,9 @@ static void decrypt(ulong32 *p, int N, ulong32 *uk)
|
||||
int n, t;
|
||||
for (t = 4*(((N-1)>>2)&1), n = N; ; ) {
|
||||
switch (n<=4 ? n : ((n-1)%4)+1) {
|
||||
case 4: pi4(p, uk+t); --n;
|
||||
case 3: pi3(p, uk+t); --n;
|
||||
case 2: pi2(p, uk+t); --n;
|
||||
case 4: pi4(p, uk+t); --n; /* FALLTHROUGH */
|
||||
case 3: pi3(p, uk+t); --n; /* FALLTHROUGH */
|
||||
case 2: pi2(p, uk+t); --n; /* FALLTHROUGH */
|
||||
case 1: pi1(p); --n; break;
|
||||
case 0: return;
|
||||
}
|
||||
|
@ -252,16 +252,19 @@ static void h_func(const unsigned char *in, unsigned char *out, unsigned char *M
|
||||
y[1] = (unsigned char)(sbox(0, (ulong32)y[1]) ^ M[4 * (6 + offset) + 1]);
|
||||
y[2] = (unsigned char)(sbox(0, (ulong32)y[2]) ^ M[4 * (6 + offset) + 2]);
|
||||
y[3] = (unsigned char)(sbox(1, (ulong32)y[3]) ^ M[4 * (6 + offset) + 3]);
|
||||
/* FALLTHROUGH */
|
||||
case 3:
|
||||
y[0] = (unsigned char)(sbox(1, (ulong32)y[0]) ^ M[4 * (4 + offset) + 0]);
|
||||
y[1] = (unsigned char)(sbox(1, (ulong32)y[1]) ^ M[4 * (4 + offset) + 1]);
|
||||
y[2] = (unsigned char)(sbox(0, (ulong32)y[2]) ^ M[4 * (4 + offset) + 2]);
|
||||
y[3] = (unsigned char)(sbox(0, (ulong32)y[3]) ^ M[4 * (4 + offset) + 3]);
|
||||
/* FALLTHROUGH */
|
||||
case 2:
|
||||
y[0] = (unsigned char)(sbox(1, sbox(0, sbox(0, (ulong32)y[0]) ^ M[4 * (2 + offset) + 0]) ^ M[4 * (0 + offset) + 0]));
|
||||
y[1] = (unsigned char)(sbox(0, sbox(0, sbox(1, (ulong32)y[1]) ^ M[4 * (2 + offset) + 1]) ^ M[4 * (0 + offset) + 1]));
|
||||
y[2] = (unsigned char)(sbox(1, sbox(1, sbox(0, (ulong32)y[2]) ^ M[4 * (2 + offset) + 2]) ^ M[4 * (0 + offset) + 2]));
|
||||
y[3] = (unsigned char)(sbox(0, sbox(1, sbox(1, (ulong32)y[3]) ^ M[4 * (2 + offset) + 3]) ^ M[4 * (0 + offset) + 3]));
|
||||
/* FALLTHROUGH */
|
||||
}
|
||||
mds_mult(y, out);
|
||||
}
|
||||
|
@ -89,16 +89,16 @@ void adler32_finish(adler32_state *ctx, void *hash, unsigned long size)
|
||||
switch (size) {
|
||||
default:
|
||||
h[3] = ctx->s[0] & 0x0ff;
|
||||
/* no break */
|
||||
/* FALLTHROUGH */
|
||||
case 3:
|
||||
h[2] = (ctx->s[0] >> 8) & 0x0ff;
|
||||
/* no break */
|
||||
/* FALLTHROUGH */
|
||||
case 2:
|
||||
h[1] = ctx->s[1] & 0x0ff;
|
||||
/* no break */
|
||||
/* FALLTHROUGH */
|
||||
case 1:
|
||||
h[0] = (ctx->s[1] >> 8) & 0x0ff;
|
||||
/* no break */
|
||||
/* FALLTHROUGH */
|
||||
case 0:
|
||||
;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user