diff options
author | Jussi Kivilinna <jussi.kivilinna@iki.fi> | 2014-12-23 12:13:50 +0200 |
---|---|---|
committer | Jussi Kivilinna <jussi.kivilinna@iki.fi> | 2014-12-25 11:16:48 +0200 |
commit | cc26106dbebeb84d481661813edc3e5aea9a7d99 (patch) | |
tree | ab9514703f8460f8c046d7c1ec711e19a44afb20 /cipher/tiger.c | |
parent | 520070e02e2e6ee7228945015573a6e1f4895ec3 (diff) | |
download | libgcrypt-cc26106dbebeb84d481661813edc3e5aea9a7d99.tar.gz |
rijndael: fix compiler warnings on ARM
* cipher/rijndael-internal.h (RIJNDAEL_context_s): Add u32 variants of
keyschedule arrays to unions u1 and u2.
(keyschedenc32, keyscheddec32): New.
* cipher/rijndael.c (u32_a_t): Remove.
(do_setkey): Add and use tkk[].data32, k_u32, tk_u32 and W_u32; Remove
casting byte arrays to u32_a_t.
(prepare_decryption, do_encrypt_fn, do_decrypt_fn): Use keyschedenc32
and keyscheddec32; Remove casting byte arrays to u32_a_t.
--
Patch fixes 'cast increases required alignment' compiler warnings that GCC was showing:
rijndael.c: In function 'do_setkey':
rijndael.c:310:13: warning: cast increases required alignment of target type [-Wcast-align]
*((u32_a_t*)tk[j]) = *((u32_a_t*)k[j]);
^
rijndael.c:310:34: warning: cast increases required alignment of target type [-Wcast-align]
*((u32_a_t*)tk[j]) = *((u32_a_t*)k[j]);
[removed the rest]
Signed-off-by: Jussi Kivilinna <jussi.kivilinna@iki.fi>
Diffstat (limited to 'cipher/tiger.c')
0 files changed, 0 insertions, 0 deletions