aboutsummaryrefslogtreecommitdiffstats
path: root/libavutil
diff options
context:
space:
mode:
authorReimar Döffinger <Reimar.Doeffinger@gmx.de>2009-03-08 14:51:25 +0000
committerReimar Döffinger <Reimar.Doeffinger@gmx.de>2009-03-08 14:51:25 +0000
commit3fb108430645c15beb3c1f1c84fdfcd92de3bdb8 (patch)
tree09da358f38b011f891a48de85cbbbb553c80add3 /libavutil
parent52a6632a2b88b8a7171a47c796fa5f26db1ed490 (diff)
downloadffmpeg-3fb108430645c15beb3c1f1c84fdfcd92de3bdb8.tar.gz
Remove/replace code disabled by major version bump.
Originally committed as revision 17875 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavutil')
-rw-r--r--libavutil/des.c14
1 files changed, 3 insertions, 11 deletions
diff --git a/libavutil/des.c b/libavutil/des.c
index 79fd531d8e..43f6c4ae2e 100644
--- a/libavutil/des.c
+++ b/libavutil/des.c
@@ -284,14 +284,6 @@ static uint64_t des_encdec(uint64_t in, uint64_t K[16], int decrypt) {
return in;
}
-#if LIBAVUTIL_VERSION_MAJOR < 50
-uint64_t ff_des_encdec(uint64_t in, uint64_t key, int decrypt) {
- uint64_t K[16];
- gen_roundkeys(K, key);
- return des_encdec(in, K, decrypt);
-}
-#endif
-
int av_des_init(AVDES *d, const uint8_t *key, int key_bits, int decrypt) {
if (key_bits != 64 && key_bits != 192)
return -1;
@@ -390,16 +382,16 @@ int main(void) {
uint64_t key[3];
uint64_t data;
uint64_t ct;
+ uint64_t roundkeys[16];
gettimeofday(&tv, NULL);
srand(tv.tv_sec * 1000 * 1000 + tv.tv_usec);
-#if LIBAVUTIL_VERSION_MAJOR < 50
key[0] = AV_RB64(test_key);
data = AV_RB64(plain);
- if (ff_des_encdec(data, key[0], 0) != AV_RB64(crypt)) {
+ gen_roundkeys(roundkeys, key[0]);
+ if (des_encdec(data, roundkeys, 0) != AV_RB64(crypt)) {
printf("Test 1 failed\n");
return 1;
}
-#endif
av_des_init(&d, test_key, 64, 0);
av_des_crypt(&d, tmp, plain, 1, NULL, 0);
if (memcmp(tmp, crypt, sizeof(crypt))) {