[FFmpeg-devel] [PATCH] avcodec/speexdec: fix decoding regressions
Michael Niedermayer
michael at niedermayer.cc
Sat Nov 9 02:15:00 EET 2024
Hi
On Thu, Nov 07, 2024 at 06:59:36PM -0500, shenleban tongying wrote:
> fix ticket #11054 and #11078
>
> * reduce false decoding errors
> * fix wrong frame_size
>
> Co-authored-by: Paul B Mahol <onemda at gmail.com>
> Signed-off-by: shenleban tongying <shenlebantongying at gmail.com>
> ---
> libavcodec/speexdec.c | 10 ++++++----
> 1 file changed, 6 insertions(+), 4 deletions(-)
>
> diff --git a/libavcodec/speexdec.c b/libavcodec/speexdec.c
> index d25823ef6e..d48bfca803 100644
> --- a/libavcodec/speexdec.c
> +++ b/libavcodec/speexdec.c
> @@ -1425,7 +1425,8 @@ static int parse_speex_extradata(AVCodecContext *avctx,
> if (s->frame_size < NB_FRAME_SIZE << (s->mode > 0) ||
> s->frame_size > INT32_MAX >> (s->mode > 0))
> return AVERROR_INVALIDDATA;
> - s->frame_size <<= (s->mode > 0);
> + s->frame_size <<= (s->mode > 1);
> + s->frame_size = FFMIN(640, s->frame_size);
> s->vbr = bytestream_get_le32(&buf);
> s->frames_per_packet = bytestream_get_le32(&buf);
> if (s->frames_per_packet <= 0 ||
There is something wrong with the whitespace, also git am refuses to apply
this automatically:
Applying: avcodec/speexdec: fix decoding regressions
Using index info to reconstruct a base tree...
error: patch failed: libavcodec/speexdec.c:1425
error: libavcodec/speexdec.c: patch does not apply
error: Did you hand edit your patch?
It does not apply to blobs recorded in its index.
Patch failed at 0001 avcodec/speexdec: fix decoding regressions
can you resumbit this without these issues or is there a git repo
from where it can be taken (in case you have problems with sending
mail)
thx
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
What is kyc? Its a tool that makes you give out your real ID, while criminals
give out a forged ID card.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 195 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20241109/8a83be2f/attachment.sig>
More information about the ffmpeg-devel
mailing list