avcodec/mpegvideo_enc: Reset stuffing bits if they are not supported

Fixes: Assertion failure
Fixes: Ticket8202

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
Michael Niedermayer 2021-05-30 18:51:09 +02:00
parent c297f7e57a
commit 996797f8ed

View file

@ -1846,6 +1846,7 @@ vbv_retry:
break;
default:
av_log(avctx, AV_LOG_ERROR, "vbv buffer overflow\n");
s->stuffing_bits = 0;
}
flush_put_bits(&s->pb);
s->frame_bits = put_bits_count(&s->pb);