[SCM] libav/experimental: Remove/replace code disabled by major version bump.

siretart at users.alioth.debian.org siretart at users.alioth.debian.org
Sun Jun 30 16:40:53 UTC 2013


The following commit has been merged in the experimental branch:
commit 3fb108430645c15beb3c1f1c84fdfcd92de3bdb8
Author: Reimar Döffinger <Reimar.Doeffinger at gmx.de>
Date:   Sun Mar 8 14:51:25 2009 +0000

    Remove/replace code disabled by major version bump.
    
    Originally committed as revision 17875 to svn://svn.ffmpeg.org/ffmpeg/trunk

diff --git a/libavutil/des.c b/libavutil/des.c
index 79fd531..43f6c4a 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))) {

-- 
Libav/FFmpeg packaging



More information about the pkg-multimedia-commits mailing list