This differs from libvorbis by stddev: 2.44 PSNR: 88.58 MAXDIFF: 41 bytes: 834304/ 834304 for the file from the ticket Fixes: Ticket11427 Regression since: dc89cf804a811c0d25f4649a99f7fab4b5b416fa This is a similar solution to what james proposed earlier in [FFmpeg-devel] [PATCH] avcodec/vorbisdec: don't abort on EOD when decoding residuals
Showing the changes to libavcodec (1 of 1 file). Show all
Unified · Split
| @@ -1469,8 +1469,10 @@ static av_always_inline int vorbis_residue_decode_internal(vorbis_context *vc, · 1468 unmodified lines | |||
| 1469 | unsigned step = FASTDIV(vr->partition_size << 1, dim << 1); | 1469 | unsigned step = FASTDIV(vr->partition_size << 1, dim << 1); |
| 1470 | vorbis_codebook codebook = vc->codebooks[vqbook]; | 1470 | vorbis_codebook codebook = vc->codebooks[vqbook]; |
| 1471 | 1471 | ||
| 1472 | if (get_bits_left(gb) <= 0) | 1472 | if (get_bits_left(gb) < 0) { |
| 1473 | return AVERROR_INVALIDDATA; | 1473 | av_log(vc->avctx, AV_LOG_ERROR, "Overread %d bits\n", -get_bits_left(gb)); |
| 1474 | return 0; | ||
| 1475 | } | ||
| 1474 | 1476 | ||
| 1475 | if (vr_type == 0) { | 1477 | if (vr_type == 0) { |
| 1476 | 1478 | ||