diff options
author | Paul B Mahol <onemda@gmail.com> | 2023-08-30 23:00:37 +0200 |
---|---|---|
committer | Paul B Mahol <onemda@gmail.com> | 2023-08-30 23:07:34 +0200 |
commit | 7aa71ab5c04cbff9ed4eb7c2925ceb33a8e4e970 (patch) | |
tree | be4fd9637519535ebfc0b05272c3b9f8e1b4bf5e /libavcodec/rka.c | |
parent | a94a6617a3e9924e093ae9be54bc639fba6a4cde (diff) | |
download | ffmpeg-7aa71ab5c04cbff9ed4eb7c2925ceb33a8e4e970.tar.gz |
avcodec/rka: do not output extra invalid samples in last frame
Diffstat (limited to 'libavcodec/rka.c')
-rw-r--r-- | libavcodec/rka.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libavcodec/rka.c b/libavcodec/rka.c index 7646d776be..92c1237d1f 100644 --- a/libavcodec/rka.c +++ b/libavcodec/rka.c @@ -949,6 +949,10 @@ static int rka_decode_frame(AVCodecContext *avctx, AVFrame *frame, } } + if (frame->nb_samples < s->frame_samples && + frame->nb_samples > s->last_nb_samples) + frame->nb_samples = s->last_nb_samples; + *got_frame_ptr = 1; return avpkt->size; |