diff options
| author | Christian Heimes <christian@python.org> | 2016-09-06 21:18:03 (GMT) |
|---|---|---|
| committer | Christian Heimes <christian@python.org> | 2016-09-06 21:18:03 (GMT) |
| commit | 87bf0febcb59a389eb62bcb467b7ec9c4974be49 (patch) | |
| tree | 2dba478dc8c94bf595fd8e491f2fd32df18a11f4 /Modules/_blake2/impl/blake2b.c | |
| parent | 90493ab30cd746d9063ec4cb76ad24e77da34702 (diff) | |
| download | cpython-87bf0febcb59a389eb62bcb467b7ec9c4974be49.zip cpython-87bf0febcb59a389eb62bcb467b7ec9c4974be49.tar.gz cpython-87bf0febcb59a389eb62bcb467b7ec9c4974be49.tar.bz2 | |
Issue #26798: for loop initial declarations are only allowed in C99 or C11 mode
Diffstat (limited to 'Modules/_blake2/impl/blake2b.c')
| -rw-r--r-- | Modules/_blake2/impl/blake2b.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Modules/_blake2/impl/blake2b.c b/Modules/_blake2/impl/blake2b.c index f9090a1..784ec00 100644 --- a/Modules/_blake2/impl/blake2b.c +++ b/Modules/_blake2/impl/blake2b.c @@ -174,9 +174,10 @@ BLAKE2_LOCAL_INLINE(int) blake2b_param_set_personal( blake2b_param *P, const uin BLAKE2_LOCAL_INLINE(int) blake2b_init0( blake2b_state *S ) { + int i; memset( S, 0, sizeof( blake2b_state ) ); - for( int i = 0; i < 8; ++i ) S->h[i] = blake2b_IV[i]; + for( i = 0; i < 8; ++i ) S->h[i] = blake2b_IV[i]; return 0; } @@ -188,10 +189,11 @@ int blake2b_init_param( blake2b_state *S, const blake2b_param *P ) const uint8_t * v = ( const uint8_t * )( blake2b_IV ); const uint8_t * p = ( const uint8_t * )( P ); uint8_t * h = ( uint8_t * )( S->h ); + int i; /* IV XOR ParamBlock */ memset( S, 0, sizeof( blake2b_state ) ); - for( int i = 0; i < BLAKE2B_OUTBYTES; ++i ) h[i] = v[i] ^ p[i]; + for( i = 0; i < BLAKE2B_OUTBYTES; ++i ) h[i] = v[i] ^ p[i]; return 0; } |
