[FFmpeg-devel] [PATCH v3] avcodec: add Actimagine VX video decoder

2021-03-18 Thread Florian Nouwt
Signed-off-by: Florian Nouwt --- Changelog |1 + configure |1 + doc/general_contents.texi |2 + libavcodec/Makefile |3 +- libavcodec/actimagine_vx.c | 1150 +++ libavcodec/actimagine_v

[FFmpeg-devel] [PATCH] configure: select child muxers for rtp_mpegts

2021-03-18 Thread Gyan Doshi
--- configure | 1 + 1 file changed, 1 insertion(+) diff --git a/configure b/configure index f0ac719d2d..be9c5b4b1c 100755 --- a/configure +++ b/configure @@ -3363,6 +3363,7 @@ opus_muxer_select="ogg_muxer" psp_muxer_select="mov_muxer" rtp_demuxer_select="sdp_demuxer" rtp_muxer_select="golomb

[FFmpeg-devel] [PATCH] avformat/rtp_mpegts: typedef MuxChain struct

2021-03-18 Thread Gyan Doshi
--- libavformat/rtpenc_mpegts.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/libavformat/rtpenc_mpegts.c b/libavformat/rtpenc_mpegts.c index 50cebf68a3..28522f8913 100644 --- a/libavformat/rtpenc_mpegts.c +++ b/libavformat/rtpenc_mpegts.c @@ -23,15 +23,15 @@ #i

Re: [FFmpeg-devel] [PATCH] avcodec/dv_profile: PAL DV files with dsf flag 0 - detect via pal flag and buf_size

2021-03-18 Thread Mark Plomer
Okay cool, I added the check for the PAL flag - this still works fine for my test-videos. I also looked at the old hack above with the codec_tag check - changed in 2013 for ticket #2177 (patch by Michael Niedermayer). I removed that more specific hack and the test-video attached to ticket #217

Re: [FFmpeg-devel] [PATCH 6/6] avutil/adler32: Switch av_adler32_update() to size_t on bump

2021-03-18 Thread James Almer
On 3/18/2021 12:43 AM, Andreas Rheinhardt wrote: av_adler32_update() is used by av_hash_update() which will be switched to size_t at the next bump. So it also has to be made to use size_t. This is also necessary for framecrcenc.c, because the size of side data will become a size_t, too. Signed-o

Re: [FFmpeg-devel] [PATCH v3] avcodec: add Actimagine VX video decoder

2021-03-18 Thread Andreas Rheinhardt
Florian Nouwt: > Signed-off-by: Florian Nouwt > --- > Changelog |1 + > configure |1 + > doc/general_contents.texi |2 + > libavcodec/Makefile |3 +- > libavcodec/actimagine_vx.c | 1150 +++

Re: [FFmpeg-devel] [PATCH v3] avcodec: add Actimagine VX video decoder

2021-03-18 Thread Zane van Iperen
On 18/3/21 8:31 pm, Florian Nouwt wrote: diff --git a/libavformat/riff.c b/libavformat/riff.c index 270ff7c024..848b1d6cfd 100644 --- a/libavformat/riff.c +++ b/libavformat/riff.c @@ -496,6 +496,8 @@ const AVCodecTag ff_codec_bmp_tags[] = { { AV_CODEC_ID_MVHA, MKTAG('M', 'V', 'H',

Re: [FFmpeg-devel] [PATCH v3] avcodec: add Actimagine VX video decoder

2021-03-18 Thread Florian Nouwt
Andreas Rheinhardt: - Why are these tables not internal to actimagine_vx.c? I separated the data because for parsing the vx container files I will need a parser, which will be in a separate file from the decoder and requires those tables. - You wasted an opportunity to add a space before '=' (th

Re: [FFmpeg-devel] [PATCH v3] avcodec: add Actimagine VX video decoder

2021-03-18 Thread Andreas Rheinhardt
Florian Nouwt: > Andreas Rheinhardt: > > - Why are these tables not internal to actimagine_vx.c? > > I separated the data because for parsing the vx container files I will > need a parser, which will be in a separate file from the decoder and > requires those tables. > > - You wasted an opportun

Re: [FFmpeg-devel] [PATCH] added parameter to dash encoder for start available time

2021-03-18 Thread Jan Ekström
On Thu, Mar 18, 2021 at 3:49 AM Jerome Berclaz wrote: > > --- > libavformat/dashenc.c | 28 > 1 file changed, 20 insertions(+), 8 deletions(-) So right now we do have an option in ffmpeg.c called itsoffset. It lets you configure the input offset in time (seconds - su

Re: [FFmpeg-devel] [PATCH] added parameter to dash encoder for start available time

2021-03-18 Thread Gyan Doshi
On 2021-03-18 20:12, Jan Ekström wrote: So right now we do have an option in ffmpeg.c called itsoffset. It lets you configure the input offset in time (seconds - such as "1337.123" or time format - such as "00:00:01.123"). The only problem with it right now is that unless you set -copyts it wil

Re: [FFmpeg-devel] [PATCH] added parameter to dash encoder for start available time

2021-03-18 Thread Jan Ekström
On Thu, Mar 18, 2021, 17:01 Gyan Doshi wrote: > > > On 2021-03-18 20:12, Jan Ekström wrote: > > So right now we do have an option in ffmpeg.c called itsoffset. It > > lets you configure the input offset in time (seconds - such as > > "1337.123" or time format - such as "00:00:01.123"). The only p

[FFmpeg-devel] [PATCH 1/2] avformat/mov: Fix extended atom size buffer length check

2021-03-18 Thread Derek Buitenhuis
When extended atom size support was added to probing in fec4a2d232d7ebf6d1084fb568d4d84844f25abc, the buffer size check was backwards, but probing continued to work because there was no minimum size check yet, so despite size being 1 on these atoms, and failing to read the 64-bit size, the tag was

[FFmpeg-devel] [PATCH 2/2] FATE: Add test for probing MOV/MP4 files with extended box sizes

2021-03-18 Thread Derek Buitenhuis
The test sample has to have no file extension, otherwise probing happens to work, based off file extension alone, and we want to test the actual proobing function. Signed-off-by: Derek Buitenhuis --- I will reply to this email with the sample file in question. --- tests/fate/mov.mak

Re: [FFmpeg-devel] [PATCH 2/2] FATE: Add test for probing MOV/MP4 files with extended box sizes

2021-03-18 Thread Derek Buitenhuis
On 18/03/2021 16:14, Derek Buitenhuis wrote: > The test sample has to have no file extension, otherwise probing > happens to work, based off file extension alone, and we want to > test the actual proobing function. > > Signed-off-by: Derek Buitenhuis > --- > I will reply to this email with the sa

Re: [FFmpeg-devel] [PATCH 2/2] FATE: Add test for probing MOV/MP4 files with extended box sizes

2021-03-18 Thread Andreas Rheinhardt
Derek Buitenhuis: > The test sample has to have no file extension, otherwise probing > happens to work, based off file extension alone, and we want to > test the actual proobing function. ^ > > Signed-off-by: Derek Buitenhuis > --- > I will reply to this email with the sample

Re: [FFmpeg-devel] [PATCH 2/2] FATE: Add test for probing MOV/MP4 files with extended box sizes

2021-03-18 Thread Derek Buitenhuis
On 18/03/2021 16:14, Derek Buitenhuis wrote: > The test sample has to have no file extension, otherwise probing > happens to work, based off file extension alone, and we want to > test the actual proobing function. > > Signed-off-by: Derek Buitenhuis > --- > I will reply to this email with the sa

[FFmpeg-devel] [PATCH 2/2 v2] FATE: Add test for probing MOV/MP4 files with extended box sizes

2021-03-18 Thread Derek Buitenhuis
The test sample has to have no file extension, otherwise probing happens to work, based off file extension alone, and we want to test the actual probing function. Signed-off-by: Derek Buitenhuis --- New features: * Less typos * A backslash --- tests/fate/mov.mak | 3 +++

Re: [FFmpeg-devel] [PATCH 2/2] FATE: Add test for probing MOV/MP4 files with extended box sizes

2021-03-18 Thread Derek Buitenhuis
On 18/03/2021 16:50, Andreas Rheinhardt wrote: >> The test sample has to have no file extension, otherwise probing >> happens to work, based off file extension alone, and we want to >> test the actual proobing function. > ^ [...] >> fate-mov-mp4-with-mov-i

[FFmpeg-devel] Patch for ticket #9151

2021-03-18 Thread Dominic Mayers
Hello, Ticket #9151 Applies to: ffmpeg version N-101612-gda12d600ea Copyright (c) 2000-2021 the FFmpeg developers built with gcc 9 (Ubuntu 9.3.0-17ubuntu1~20.04) Compiled ffmpeg to include libtesseract by adding --enable-libtesseract to the configuration Issue: The current version of libavfi

[FFmpeg-devel] [PATCH] Make font shaping a shared subtitle filter option

2021-03-18 Thread yorwba
Commit 4b58349bc8ff2ff5dfbc9eef1e5856fd16e1f517 introduced a new option for selecting the font shaping engine used for rendering ASS subtitles. However, the shaping value was used in code shared with the ordinary subtitles filter (config_input in vf_subtitles.c), where it is left uninitialized, as

[FFmpeg-devel] [PATCH 1/4] avformat/avidec: Check for dv streams before using priv_data in parse ##dc/##wb

2021-03-18 Thread Michael Niedermayer
Fixes: null pointer dereference Fixes: 31588/clusterfuzz-testcase-minimized-ffmpeg_dem_AVI_fuzzer-6165716135968768 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer --- libavformat/avidec.c | 2 +- 1 file chan

[FFmpeg-devel] [PATCH 3/4] avformat/movenc: Avoid loosing cluster array on failure

2021-03-18 Thread Michael Niedermayer
Fixes: crash Fixes: check_pkt.mp4 Found-by: Rafael Dutra Signed-off-by: Michael Niedermayer --- libavformat/movenc.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/libavformat/movenc.c b/libavformat/movenc.c index 6790fe6c45..bade57dcea 100644 --- a/libavformat/movenc.

[FFmpeg-devel] [PATCH 2/4] tools/target_dec_fuzzer: Adjust VP4 threshold

2021-03-18 Thread Michael Niedermayer
Fixes: Timeout (>10sec -> <100ms) Fixes: 31515/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_VP4_fuzzer-5247114134290432 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer --- tools/target_dec_fuzzer.c | 1

[FFmpeg-devel] [PATCH 4/4] avcodec/mpegpicture: Keep ff_mpeg_framesize_alloc() failure state consistent

2021-03-18 Thread Michael Niedermayer
Fixes: null pointer dereference Fixes: ff_put_pixels16_sse2.mp4 Found-by: Rafael Dutra Signed-off-by: Michael Niedermayer --- libavcodec/mpegpicture.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libavcodec/mpegpicture.c b/libavcodec/mpegpicture.c index e3f648895d..06

Re: [FFmpeg-devel] [PATCH] avformat/utils: Preserve AV_PKT_FLAG_CORRUPT

2021-03-18 Thread Marton Balint
On Wed, 17 Mar 2021, Pavel Koshevoy wrote: Preserve AV_PKT_FLAG_CORRUPT so the caller can decide whether to drop the packet. LGTM, but Michael was against it last time: https://patchwork.ffmpeg.org/project/ffmpeg/patch/20181009233214.8785-2-...@passwd.hu/ Regards, Marton --- libavformat/

Re: [FFmpeg-devel] [PATCH] avcodec/dv_profile: PAL DV files with dsf flag 0 - detect via pal flag and buf_size

2021-03-18 Thread Marton Balint
On Thu, 18 Mar 2021, Mark Plomer wrote: Okay cool, I added the check for the PAL flag - this still works fine for my test-videos. I also looked at the old hack above with the codec_tag check - changed in 2013 for ticket #2177 (patch by Michael Niedermayer). I removed that more specific hac

Re: [FFmpeg-devel] [PATCH 4/4] avcodec/mpegpicture: Keep ff_mpeg_framesize_alloc() failure state consistent

2021-03-18 Thread Andreas Rheinhardt
Michael Niedermayer: > Fixes: null pointer dereference > Fixes: ff_put_pixels16_sse2.mp4 > > Found-by: Rafael Dutra > Signed-off-by: Michael Niedermayer > --- > libavcodec/mpegpicture.c | 5 - > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/libavcodec/mpegpicture.c b/liba

Re: [FFmpeg-devel] [PATCH] avformat/utils: Preserve AV_PKT_FLAG_CORRUPT

2021-03-18 Thread Pavel Koshevoy
On Thu, Mar 18, 2021 at 2:51 PM Marton Balint wrote: > > > On Wed, 17 Mar 2021, Pavel Koshevoy wrote: > > > Preserve AV_PKT_FLAG_CORRUPT so the caller can decide whether to drop > > the packet. > > LGTM, but Michael was against it last time: > > > https://patchwork.ffmpeg.org/project/ffmpeg/patch

Re: [FFmpeg-devel] [PATCH] avformat/utils: Preserve AV_PKT_FLAG_CORRUPT

2021-03-18 Thread Pavel Koshevoy
On Thu, Mar 18, 2021 at 2:57 PM Pavel Koshevoy wrote: > > > On Thu, Mar 18, 2021 at 2:51 PM Marton Balint wrote: > >> >> >> On Wed, 17 Mar 2021, Pavel Koshevoy wrote: >> >> > Preserve AV_PKT_FLAG_CORRUPT so the caller can decide whether to drop >> > the packet. >> >> LGTM, but Michael was agains

Re: [FFmpeg-devel] [PATCH] added parameter to dash encoder for start available time

2021-03-18 Thread Jan Ekström
On Thu, Mar 18, 2021 at 5:07 PM Jan Ekström wrote: > > On Thu, Mar 18, 2021, 17:01 Gyan Doshi wrote: >> >> >> >> On 2021-03-18 20:12, Jan Ekström wrote: >> > So right now we do have an option in ffmpeg.c called itsoffset. It >> > lets you configure the input offset in time (seconds - such as >> >

Re: [FFmpeg-devel] [PATCH 6/6] avutil/adler32: Switch av_adler32_update() to size_t on bump

2021-03-18 Thread Andreas Rheinhardt
James Almer: > On 3/18/2021 12:43 AM, Andreas Rheinhardt wrote: >> av_adler32_update() is used by av_hash_update() which will be switched >> to size_t at the next bump. So it also has to be made to use size_t. >> This is also necessary for framecrcenc.c, because the size of side data >> will become

Re: [FFmpeg-devel] [PATCH 1/4] avformat/avidec: Check for dv streams before using priv_data in parse ##dc/##wb

2021-03-18 Thread Andreas Rheinhardt
Michael Niedermayer: > Fixes: null pointer dereference > Fixes: > 31588/clusterfuzz-testcase-minimized-ffmpeg_dem_AVI_fuzzer-6165716135968768 > > Found-by: continuous fuzzing process > https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg > Signed-off-by: Michael Niedermayer > --- > l

Re: [FFmpeg-devel] [PATCH 1/4] avformat/avidec: Check for dv streams before using priv_data in parse ##dc/##wb

2021-03-18 Thread Michael Niedermayer
On Fri, Mar 19, 2021 at 12:20:23AM +0100, Andreas Rheinhardt wrote: > Michael Niedermayer: > > Fixes: null pointer dereference > > Fixes: > > 31588/clusterfuzz-testcase-minimized-ffmpeg_dem_AVI_fuzzer-6165716135968768 > > > > Found-by: continuous fuzzing process > > https://github.com/google/oss

Re: [FFmpeg-devel] [PATCH 1/4] avformat/avidec: Check for dv streams before using priv_data in parse ##dc/##wb

2021-03-18 Thread Andreas Rheinhardt
Michael Niedermayer: > On Fri, Mar 19, 2021 at 12:20:23AM +0100, Andreas Rheinhardt wrote: >> Michael Niedermayer: >>> Fixes: null pointer dereference >>> Fixes: >>> 31588/clusterfuzz-testcase-minimized-ffmpeg_dem_AVI_fuzzer-6165716135968768 >>> >>> Found-by: continuous fuzzing process >>> https:

[FFmpeg-devel] [PATCH 1/4] avformat/tests/fifo_muxer: Fix leak of AVPacket on error

2021-03-18 Thread Andreas Rheinhardt
Also factor allocating and freeing the packet out. Fixes Coverity issues #1473722 and #1473723; it is a regression since 4b386b2059806ca7ee7f991d2c8b735410693e8c. Signed-off-by: Andreas Rheinhardt --- libavformat/tests/fifo_muxer.c | 37 ++ 1 file changed, 15 inse

[FFmpeg-devel] [PATCH 2/4] avformat/tests/fifo_muxer: Fix memleak on error, fix API violation

2021-03-18 Thread Andreas Rheinhardt
The test program for the FIFO muxer allocates a buffer without padding and wraps it into a packet via av_packet_from_data(). This is an API violation. Furthermore, said buffer leaks in case av_packet_from_data() fails. Fix both of these issues by using av_new_packet() instead. Signed-off-by: Andre

[FFmpeg-devel] [PATCH 3/4] avcodec/libxvid: Fix leak of AVPacket on error

2021-03-18 Thread Andreas Rheinhardt
Regression since 2101b99777860c853ca2321031eb3f4047dc5894. Fixes Coverity issue #1473721. Signed-off-by: Andreas Rheinhardt --- libavcodec/libxvid.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libavcodec/libxvid.c b/libavcodec/libxvid.c index 7dc6859571..25b0025d5f 100

[FFmpeg-devel] [PATCH 4/4] avcodec/libxvid: Remove set-but-unused variable

2021-03-18 Thread Andreas Rheinhardt
Set-but-unused since 2101b99777860c853ca2321031eb3f4047dc5894. Signed-off-by: Andreas Rheinhardt --- Before 2101b99777 the packet was only unreferenced on success so that said commit seems to have fixed a potential memleak. libavcodec/libxvid.c | 4 ++-- 1 file changed, 2 insertions(+), 2 delet

Re: [FFmpeg-devel] [PATCH 3/4] avcodec/libxvid: Fix leak of AVPacket on error

2021-03-18 Thread James Almer
On 3/18/2021 9:52 PM, Andreas Rheinhardt wrote: Regression since 2101b99777860c853ca2321031eb3f4047dc5894. Fixes Coverity issue #1473721. Signed-off-by: Andreas Rheinhardt --- libavcodec/libxvid.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libavcodec/libxvid.c b/l

Re: [FFmpeg-devel] [PATCH 1/4] avformat/tests/fifo_muxer: Fix leak of AVPacket on error

2021-03-18 Thread James Almer
On 3/18/2021 9:52 PM, Andreas Rheinhardt wrote: Also factor allocating and freeing the packet out. Fixes Coverity issues #1473722 and #1473723; it is a regression since 4b386b2059806ca7ee7f991d2c8b735410693e8c. Signed-off-by: Andreas Rheinhardt --- libavformat/tests/fifo_muxer.c | 37

Re: [FFmpeg-devel] [PATCH 1/6] avcodec/utils: Check earlier for codec id/type mismatch

2021-03-18 Thread Andreas Rheinhardt
Andreas Rheinhardt: > These fields can't be set via AVOptions, ergo one can check them before > having allocated anything. > > Signed-off-by: Andreas Rheinhardt > --- > libavcodec/utils.c | 24 > 1 file changed, 12 insertions(+), 12 deletions(-) > > diff --git a/libavco

[FFmpeg-devel] [PATCH] avcodec/libxvid: remove unnecessary output packet data check

2021-03-18 Thread James Almer
The user buffers passed to avcodec_encode_video2() haven't been propagated to AVCodec.encode2 implementations since 93016f5d1d280f9cb7856883af287fa66affc04c. Also, the generic encode code already unrefs the packet if nothing was encoded. Signed-off-by: James Almer --- libavcodec/libxvid.c | 4 +-

Re: [FFmpeg-devel] [PATCH v2 5/6] Fix printf specifiers for variables that will be switched to size_t

2021-03-18 Thread James Almer
On 3/18/2021 12:43 AM, Andreas Rheinhardt wrote: diff --git a/libavformat/webvttenc.c b/libavformat/webvttenc.c index 552bc38b65..342cba6dd8 100644 --- a/libavformat/webvttenc.c +++ b/libavformat/webvttenc.c @@ -72,8 +72,13 @@ static int webvtt_write_packet(AVFormatContext *ctx, AVPacket *pkt)

Re: [FFmpeg-devel] [PATCH] added parameter to dash encoder for start available time

2021-03-18 Thread Gyan Doshi
On 2021-03-19 03:22, Jan Ekström wrote: On Thu, Mar 18, 2021 at 5:07 PM Jan Ekström wrote: On Thu, Mar 18, 2021, 17:01 Gyan Doshi wrote: On 2021-03-18 20:12, Jan Ekström wrote: So right now we do have an option in ffmpeg.c called itsoffset. It lets you configure the input offset in time

[FFmpeg-devel] [PATCH 01/18] libavformat/utils: Fix indentation

2021-03-18 Thread Andreas Rheinhardt
Originally added in 12f996edfab67b65af0ff1ee829f9eeabb025b0f behind #if 0; aebb56e1844d61965c97e95534c3ae0da69df028 then removed the #if and replaced it by using av_dlog. Then commit 1a3eb042c704dea190c644def5b32c9cee8832b8 replaced this with av_log at trace level. Yet the code block always stayed

[FFmpeg-devel] [PATCH 02/18] avformat/utils: Always leave parse_pkt in blank state, avoid resetting

2021-03-18 Thread Andreas Rheinhardt
Always leaving said packet in a blank state after having used it allows to avoid having to reset it before one uses it; and it also allows to use it in more places than just in parse_packets() here. Signed-off-by: Andreas Rheinhardt --- libavformat/utils.c | 6 +++--- 1 file changed, 3 insertion

[FFmpeg-devel] [PATCH 03/18] avformat/utils: Don't allocate separate packet for extract_extradata

2021-03-18 Thread Andreas Rheinhardt
One can simply reuse AVFormatInternal.parse_pkt instead. Signed-off-by: Andreas Rheinhardt --- libavformat/internal.h | 12 ++-- libavformat/utils.c| 29 ++--- 2 files changed, 20 insertions(+), 21 deletions(-) diff --git a/libavformat/internal.h b/libavforma

[FFmpeg-devel] [PATCH 04/18] avformat/matroskadec: Reuse AVFormatInternal.parse_pkt

2021-03-18 Thread Andreas Rheinhardt
Before 8d78e90a6ba96646f7f25aff6ca3e12e71cec164 the Matroska demuxer used stack packets to hold temporary packets; now it uses a temporary packet allocated by the Matroska demuxer. Yet because it used stack packets the code has always properly reset the packet on error, while on success these tempo

[FFmpeg-devel] [PATCH 05/18] avformat/moflex: Simplify freeing packets

2021-03-18 Thread Andreas Rheinhardt
Signed-off-by: Andreas Rheinhardt --- libavformat/moflex.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/libavformat/moflex.c b/libavformat/moflex.c index 41335ada78..dabe113e6b 100644 --- a/libavformat/moflex.c +++ b/libavformat/moflex.c @@ -369,10 +369,7 @@ static int

[FFmpeg-devel] [PATCH 06/18] avformat/apetag: Avoid stack packet when reading attached picture

2021-03-18 Thread Andreas Rheinhardt
Read it directly into AVStream.attached_pic. Signed-off-by: Andreas Rheinhardt --- libavformat/apetag.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/libavformat/apetag.c b/libavformat/apetag.c index 454c6c688b..23ee6b516d 100644 --- a/libavformat/apetag.c +++ b/libavfor

[FFmpeg-devel] [PATCH 13/18] avformat/ipmovie: Avoid stack packet

2021-03-18 Thread Andreas Rheinhardt
Replace it in ipmovie_read_header() by AVFormatInternal.parse_pkt which is unused when reading the header. Signed-off-by: Andreas Rheinhardt --- libavformat/ipmovie.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/libavformat/ipmovie.c b/libavformat/ipmovie.c index 048e74

[FFmpeg-devel] [PATCH 07/18] avformat/asfdec_f: Avoid stack packet

2021-03-18 Thread Andreas Rheinhardt
Replace it by using AVFormatInternal.parse_pkt which is otherwise unused when reading a header. Signed-off-by: Andreas Rheinhardt --- libavformat/asfdec_f.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/libavformat/asfdec_f.c b/libavformat/asfdec_f.c index 1484b544d

[FFmpeg-devel] [PATCH 14/18] avformat/webpenc: Use init instead of write_header function

2021-03-18 Thread Andreas Rheinhardt
webp_write_header() didn't write anything. Signed-off-by: Andreas Rheinhardt --- libavformat/webpenc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libavformat/webpenc.c b/libavformat/webpenc.c index 9fb472257d..8c32ff66df 100644 --- a/libavformat/webpenc.c +++ b/libav

[FFmpeg-devel] [PATCH 08/18] avformat/ipmovie: Remove redundant av_packet_unref()

2021-03-18 Thread Andreas Rheinhardt
When one of these errors happens during ipmovie_read_packet(), an error is returned and the packet is cleaned up generically. And since 712d3ac539f30239b764d8621829dc9dc913da61 the same happens in ipmovie_read_header(). Signed-off-by: Andreas Rheinhardt --- libavformat/ipmovie.c | 3 --- 1 file

[FFmpeg-devel] [PATCH 15/18] avformat/webpenc: Fix memleak when using invalid packets

2021-03-18 Thread Andreas Rheinhardt
The WebP muxer uses sometimes caches a packet it receives to write it later; yet if a cached packet is too small (so small as to be invalid), it is cached, but not written and not unreferenced. Such a packet leaks, either by being overwritten by the next frame or because it is never unreferenced at

[FFmpeg-devel] [PATCH 09/18] avformat/ipmovie: Avoid reading packets during read_header

2021-03-18 Thread Andreas Rheinhardt
They will be discarded anyway because this can only happen for invalid data. This already implies that the pkt won't be used at all when parsing the very first chunk when reading the header, so one can use NULL as argument and remove the av_packet_unref() on error. Signed-off-by: Andreas Rheinhard

[FFmpeg-devel] [PATCH 16/18] avformat/webpenc: Reindentation

2021-03-18 Thread Andreas Rheinhardt
Signed-off-by: Andreas Rheinhardt --- libavformat/webpenc.c | 22 +++--- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/libavformat/webpenc.c b/libavformat/webpenc.c index e3b12aeed2..d5edf89289 100644 --- a/libavformat/webpenc.c +++ b/libavformat/webpenc.c @@ -53

[FFmpeg-devel] [PATCH 10/18] avformat/ipmovie: Deduplicate parsing video data opcodes

2021-03-18 Thread Andreas Rheinhardt
Signed-off-by: Andreas Rheinhardt --- libavformat/ipmovie.c | 23 +++ 1 file changed, 3 insertions(+), 20 deletions(-) diff --git a/libavformat/ipmovie.c b/libavformat/ipmovie.c index 3f40bb8fe8..f1cc30b6c0 100644 --- a/libavformat/ipmovie.c +++ b/libavformat/ipmovie.c @@ -56

[FFmpeg-devel] [PATCH 17/18] avformat/webpenc: Fix memleak when trailer is never written

2021-03-18 Thread Andreas Rheinhardt
When the trailer is never written (or when a stream switches from non-animation mode to animation mode mid-stream), a cached packet (if existing) would leak. Fix this by adding a deinit function. Signed-off-by: Andreas Rheinhardt --- AVFormatInternal.parse_pkt is completely unused for muxers, so

[FFmpeg-devel] [PATCH 11/18] avformat/ipmovie: Fix indentation

2021-03-18 Thread Andreas Rheinhardt
Signed-off-by: Andreas Rheinhardt --- libavformat/ipmovie.c | 34 +- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/libavformat/ipmovie.c b/libavformat/ipmovie.c index f1cc30b6c0..a71575235f 100644 --- a/libavformat/ipmovie.c +++ b/libavformat/ipmo

[FFmpeg-devel] [PATCH 12/18] avformat/ipmovie: Remove redundant initializations

2021-03-18 Thread Andreas Rheinhardt
The demuxer's context has already been zeroed generically. Signed-off-by: Andreas Rheinhardt --- libavformat/ipmovie.c | 7 --- 1 file changed, 7 deletions(-) diff --git a/libavformat/ipmovie.c b/libavformat/ipmovie.c index a71575235f..048e748cfd 100644 --- a/libavformat/ipmovie.c +++ b/lib

[FFmpeg-devel] [PATCH 18/18] avformat/amvenc: Remove unnecessary av_packet_free()

2021-03-18 Thread Andreas Rheinhardt
The muxer's deinit function takes care of cleaning up when init fails. Signed-off-by: Andreas Rheinhardt --- libavformat/amvenc.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/libavformat/amvenc.c b/libavformat/amvenc.c index 5d13b618f4..362b474fa6 100644 --- a/libavformat/amvenc.c +++ b/