From: Michael Niedermayer <michael@niedermayer.cc>
To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org>
Subject: Re: [FFmpeg-devel] [PATCH 2/2] avcodec/speexdec: fix setting frame_size from extradata
Date: Fri, 16 Feb 2024 04:29:08 +0100
Message-ID: <20240216032908.GI6420@pb2> (raw)
In-Reply-To: <20240120014730.53635-2-jamrial@gmail.com>
[-- Attachment #1.1: Type: text/plain, Size: 3035 bytes --]
On Fri, Jan 19, 2024 at 10:47:30PM -0300, James Almer wrote:
> Finishes fixing vp5/potter512-400-partial.avi
>
> The fate-matroska-ms-mode test ref is updated to reflect that the Speex decoder
> can now read the stream.
>
> Signed-off-by: James Almer <jamrial@gmail.com>
> ---
> libavcodec/speexdec.c | 4 +---
> tests/ref/fate/matroska-ms-mode | 2 +-
> 2 files changed, 2 insertions(+), 4 deletions(-)
Theres plenty of code remaining after this change that assumes NB_FRAME_SIZE
are available and writes that also.
There was a testcase reporrted that causes this and many others
ill forward the testcase.
==18747== Invalid write of size 4
==18747== at 0xD1CFC3: sb_decode (speexdec.c:1260)
==18747== by 0xD1E5CE: speex_decode_frame (speexdec.c:1557)
==18747== by 0x998846: decode_simple_internal (decode.c:430)
==18747== by 0x998DD7: decode_simple_receive_frame (decode.c:609)
==18747== by 0x998F47: decode_receive_frame_internal (decode.c:637)
==18747== by 0x99930C: avcodec_send_packet (decode.c:734)
==18747== by 0x669D2F: try_decode_frame (demux.c:2126)
==18747== by 0x66CAA0: avformat_find_stream_info (demux.c:2809)
==18747== by 0x24E9C2: ifile_open (ffmpeg_demux.c:1663)
==18747== by 0x2755BE: open_files (ffmpeg_opt.c:1333)
==18747== by 0x275780: ffmpeg_parse_options (ffmpeg_opt.c:1373)
==18747== by 0x289702: main (ffmpeg.c:1032)
==18747== Address 0x16a170c0 is 0 bytes after a block of size 1,536 alloc'd
==18747== at 0x4C33E76: memalign (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==18747== by 0x4C33F91: posix_memalign (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==18747== by 0x13E3FE6: av_malloc (mem.c:105)
==18747== by 0x13BFBFD: av_buffer_alloc (buffer.c:82)
==18747== by 0x13C0645: pool_alloc_buffer (buffer.c:362)
==18747== by 0x13C07C6: av_buffer_pool_get (buffer.c:401)
==18747== by 0xA46052: audio_get_buffer (get_buffer.c:203)
==18747== by 0xA4648D: avcodec_default_get_buffer2 (get_buffer.c:278)
==18747== by 0x99B967: ff_get_buffer (decode.c:1673)
==18747== by 0xD1E52E: speex_decode_frame (speexdec.c:1552)
==18747== by 0x998846: decode_simple_internal (decode.c:430)
==18747== by 0x998DD7: decode_simple_receive_frame (decode.c:609)
==18747== by 0x998F47: decode_receive_frame_internal (decode.c:637)
==18747== by 0x99930C: avcodec_send_packet (decode.c:734)
==18747== by 0x669D2F: try_decode_frame (demux.c:2126)
==18747== by 0x66CAA0: avformat_find_stream_info (demux.c:2809)
==18747== by 0x24E9C2: ifile_open (ffmpeg_demux.c:1663)
==18747== by 0x2755BE: open_files (ffmpeg_opt.c:1333)
==18747== by 0x275780: ffmpeg_parse_options (ffmpeg_opt.c:1373)
==18747== by 0x289702: main (ffmpeg.c:1032)
thx
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Good people do not need laws to tell them to act responsibly, while bad
people will find a way around the laws. -- Plato
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]
[-- Attachment #2: Type: text/plain, Size: 251 bytes --]
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
prev parent reply other threads:[~2024-02-16 3:29 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-20 1:47 [FFmpeg-devel] [PATCH 1/2] avcodec/speexdec: relax the extradata check for the speex string James Almer
2024-01-20 1:47 ` [FFmpeg-devel] [PATCH 2/2] avcodec/speexdec: fix setting frame_size from extradata James Almer
2024-01-24 14:35 ` Andreas Rheinhardt
2024-01-24 18:52 ` James Almer
2024-02-16 3:29 ` Michael Niedermayer [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240216032908.GI6420@pb2 \
--to=michael@niedermayer.cc \
--cc=ffmpeg-devel@ffmpeg.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
This inbox may be cloned and mirrored by anyone:
git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
ffmpegdev@gitmailbox.com
public-inbox-index ffmpegdev
Example config snippet for mirrors.
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git