X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavutil%2Fdes.c;h=15ae50346690afd3af990098ea07af316f39c8d0;hb=976a8b217986fecdbe1fdcaa3e14ce9c3c92eb25;hp=9c1a530666fd422fa916fa793fd077130d1d125c;hpb=58c03f6d7d6eabdbc25103e8229a06ddf3718bb9;p=ffmpeg diff --git a/libavutil/des.c b/libavutil/des.c index 9c1a530666f..15ae5034669 100644 --- a/libavutil/des.c +++ b/libavutil/des.c @@ -39,6 +39,7 @@ static const uint8_t IP_shuffle[] = { }; #undef T +#if defined(CONFIG_SMALL) || defined(GENTABLES) #define T(a, b, c, d) 32-a,32-b,32-c,32-d static const uint8_t P_shuffle[] = { T(16, 7, 20, 21), @@ -51,6 +52,7 @@ static const uint8_t P_shuffle[] = { T(22, 11, 4, 25) }; #undef T +#endif #define T(a, b, c, d, e, f, g) 64-a,64-b,64-c,64-d,64-e,64-f,64-g static const uint8_t PC1_shuffle[] = { @@ -240,7 +242,7 @@ static uint32_t f_func(uint32_t r, uint64_t k) { } /** - * \brief rotate the two halves of the expanded 56 bit key each 1 bit left + * @brief rotate the two halves of the expanded 56 bit key each 1 bit left * * Note: the specification calls this "shift", so I kept it although * it is confusing. @@ -402,7 +404,7 @@ int main(void) { printf("Partial Monte-Carlo test failed\n"); return 1; } - for (i = 0; i < 1000000; i++) { + for (i = 0; i < 1000; i++) { key[0] = rand64(); key[1] = rand64(); key[2] = rand64(); data = rand64(); av_des_init(&d, key, 192, 0);