diff options
author | Michael Niedermayer <michael@niedermayer.cc> | 2025-06-27 18:09:24 +0200 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2025-06-28 23:54:40 +0200 |
commit | cfd1f81e7d06e64cc03d670bafe739cc8925f5be (patch) | |
tree | 69d0ded44982bad9b96f1025c2993328da8c61eb | |
parent | 89ec66d61b2c53e42a29bc437a152b9d8556a312 (diff) | |
download | ffmpeg-cfd1f81e7d06e64cc03d670bafe739cc8925f5be.tar.gz |
avcodec/speexdec: consider differing frame sizes in remaining space check
Fixes: talk109-q5.spx
Regression since: f6986e75be87f512f65d64ac91ba19d505a8d210
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r-- | libavcodec/speexdec.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/speexdec.c b/libavcodec/speexdec.c index 94dce5420c..ba9faeb15d 100644 --- a/libavcodec/speexdec.c +++ b/libavcodec/speexdec.c @@ -1234,7 +1234,7 @@ static int sb_decode(AVCodecContext *avctx, void *ptr_st, mode = st->mode; if (st->modeID > 0) { - if (packets_left <= 1) + if (packets_left * s->frame_size < 2*st->frame_size) return AVERROR_INVALIDDATA; low_innov_alias = out + st->frame_size; s->st[st->modeID - 1].innov_save = low_innov_alias; |