diff options
author | Mans Rullgard <mans@mansr.com> | 2011-07-03 11:20:39 +0100 |
---|---|---|
committer | Mans Rullgard <mans@mansr.com> | 2011-07-03 13:41:42 +0100 |
commit | 8f175810beba0e4d7fb76c6eb747e5aab76071b4 (patch) | |
tree | 46444bdfbe53bc5463dd1057b19a578b9a279bef /libavutil/aes.c | |
parent | 66fe5970abdad0964d0e0d0e100b62e715922886 (diff) | |
download | ffmpeg-8f175810beba0e4d7fb76c6eb747e5aab76071b4.tar.gz |
aes: fix for big endian systems
This was missed in 5d20f19 since CONFIG_SMALL was always broken
for big endian.
Signed-off-by: Mans Rullgard <mans@mansr.com>
Diffstat (limited to 'libavutil/aes.c')
-rw-r--r-- | libavutil/aes.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/libavutil/aes.c b/libavutil/aes.c index 8a8bfc2b25..d1fe857914 100644 --- a/libavutil/aes.c +++ b/libavutil/aes.c @@ -54,7 +54,11 @@ static uint32_t enc_multbl[4][256]; static uint32_t dec_multbl[4][256]; #endif -#define ROT(x, s) ((x << s) | (x >> (32-s))) +#if HAVE_BIGENDIAN +# define ROT(x, s) ((x >> s) | (x << (32-s))) +#else +# define ROT(x, s) ((x << s) | (x >> (32-s))) +#endif static inline void addkey(av_aes_block *dst, const av_aes_block *src, const av_aes_block *round_key) |