History

Remove/replace code disabled by major version bump.

Originally committed as revision 17875 to svn://svn.ffmpeg.org/ffmpeg/trunk

Reimar Döffinger committed 17 years ago

Commit 3fb10841 parent 52a66321 file · +3 −11Browse files

Unified · Split

libavutil/des.c+3−11
@@ -284,14 +284,6 @@ static uint64_t des_encdec(uint64_t in, uint64_t K[16], int decrypt) { · 283 unmodified lines
284284 return in;
285285 }
286286
287−#if LIBAVUTIL_VERSION_MAJOR < 50
288−uint64_t ff_des_encdec(uint64_t in, uint64_t key, int decrypt) {
289− uint64_t K[16];
290− gen_roundkeys(K, key);
291− return des_encdec(in, K, decrypt);
292−}
293−#endif
294−
295287 int av_des_init(AVDES *d, const uint8_t *key, int key_bits, int decrypt) {
296288 if (key_bits != 64 && key_bits != 192)
297289 return -1;
@@ -390,16 +382,16 @@ int main(void) { · 92 unmodified lines
390382 uint64_t key[3];
391383 uint64_t data;
392384 uint64_t ct;
385+ uint64_t roundkeys[16];
393386 gettimeofday(&tv, NULL);
394387 srand(tv.tv_sec * 1000 * 1000 + tv.tv_usec);
395−#if LIBAVUTIL_VERSION_MAJOR < 50
396388 key[0] = AV_RB64(test_key);
397389 data = AV_RB64(plain);
398− if (ff_des_encdec(data, key[0], 0) != AV_RB64(crypt)) {
390+ gen_roundkeys(roundkeys, key[0]);
391+ if (des_encdec(data, roundkeys, 0) != AV_RB64(crypt)) {
399392 printf("Test 1 failed\n");
400393 return 1;
401394 }
402−#endif
403395 av_des_init(&d, test_key, 64, 0);
404396 av_des_crypt(&d, tmp, plain, 1, NULL, 0);
405397 if (memcmp(tmp, crypt, sizeof(crypt))) {

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t