mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-02-04 06:08:26 +02:00
avcodec/asvenc: Replace bitstream space check by assert
This should never be untrue, if it is, thats a bug Reviewed-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
9520d51e21
commit
6747a63397
@ -173,10 +173,7 @@ static inline int encode_mb(ASV1Context *a, int16_t block[6][64])
|
|||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
if (a->pb.buf_end - a->pb.buf - (put_bits_count(&a->pb) >> 3) < MAX_MB_SIZE) {
|
av_assert0(a->pb.buf_end - a->pb.buf - (put_bits_count(&a->pb) >> 3) >= MAX_MB_SIZE);
|
||||||
av_log(a->avctx, AV_LOG_ERROR, "encoded frame too large\n");
|
|
||||||
return -1;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (a->avctx->codec_id == AV_CODEC_ID_ASV1) {
|
if (a->avctx->codec_id == AV_CODEC_ID_ASV1) {
|
||||||
for (i = 0; i < 6; i++)
|
for (i = 0; i < 6; i++)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user