Don't use a C99 for loop.
Because it's 2015 and we can't depend on C99 support yet. Change-Id: Ie33fddc2a27024d4d3d50dea725062b59670a060
This commit is contained in:
parent
98d2f1fbe0
commit
6a2de3c1d4
@ -104,7 +104,8 @@ static int des_ecb_cipher(EVP_CIPHER_CTX *ctx, uint8_t *out, const uint8_t *in,
|
|||||||
in_len -= ctx->cipher->block_size;
|
in_len -= ctx->cipher->block_size;
|
||||||
|
|
||||||
EVP_DES_KEY *dat = (EVP_DES_KEY *) ctx->cipher_data;
|
EVP_DES_KEY *dat = (EVP_DES_KEY *) ctx->cipher_data;
|
||||||
for (size_t i = 0; i <= in_len; i += ctx->cipher->block_size) {
|
size_t i;
|
||||||
|
for (i = 0; i <= in_len; i += ctx->cipher->block_size) {
|
||||||
DES_ecb_encrypt((DES_cblock *) (in + i), (DES_cblock *) (out + i),
|
DES_ecb_encrypt((DES_cblock *) (in + i), (DES_cblock *) (out + i),
|
||||||
&dat->ks.ks, ctx->encrypt);
|
&dat->ks.ks, ctx->encrypt);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user