comparison flacdec.c @ 9230:35370ebfbeeb libavcodec

flacdec: remove unneeded local variable
author jbr
date Sun, 22 Mar 2009 18:59:00 +0000
parents aec6d4ca45a3
children 2c3b2ce51b04
comparison
equal deleted inserted replaced
9229:aec6d4ca45a3 9230:35370ebfbeeb
480 return 0; 480 return 0;
481 } 481 }
482 482
483 static int decode_frame(FLACContext *s, int alloc_data_size) 483 static int decode_frame(FLACContext *s, int alloc_data_size)
484 { 484 {
485 int bs_code, sr_code, bps_code, i, crc8; 485 int bs_code, sr_code, bps_code, i;
486 int ch_mode, bps, blocksize, samplerate; 486 int ch_mode, bps, blocksize, samplerate;
487 GetBitContext *gb = &s->gb; 487 GetBitContext *gb = &s->gb;
488 488
489 bs_code = get_bits(gb, 4); 489 bs_code = get_bits(gb, 4);
490 490
564 sr_code); 564 sr_code);
565 return -1; 565 return -1;
566 } 566 }
567 567
568 skip_bits(gb, 8); 568 skip_bits(gb, 8);
569 crc8 = av_crc(av_crc_get_table(AV_CRC_8_ATM), 0, 569 if (av_crc(av_crc_get_table(AV_CRC_8_ATM), 0, gb->buffer,
570 gb->buffer, get_bits_count(gb)/8); 570 get_bits_count(gb)/8)) {
571 if (crc8) { 571 av_log(s->avctx, AV_LOG_ERROR, "header crc mismatch\n");
572 av_log(s->avctx, AV_LOG_ERROR, "header crc mismatch crc=%2X\n", crc8);
573 return -1; 572 return -1;
574 } 573 }
575 574
576 s->blocksize = blocksize; 575 s->blocksize = blocksize;
577 s->samplerate = samplerate; 576 s->samplerate = samplerate;