* [FFmpeg-devel] [PATCH 1/3] avfilter/af_afftdn: Assert format
@ 2024-06-10 19:09 Michael Niedermayer
2024-06-10 19:09 ` [FFmpeg-devel] [PATCH 2/3] avfilter/af_afir: " Michael Niedermayer
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Michael Niedermayer @ 2024-06-10 19:09 UTC (permalink / raw)
To: FFmpeg development discussions and patches
Maybe helps: CID1515514 Uninitialized scalar variable
Maybe helps: CID1515517 Uninitialized scalar variable
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
---
libavfilter/af_afftdn.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/libavfilter/af_afftdn.c b/libavfilter/af_afftdn.c
index 96c2246074c..a2e6ca61076 100644
--- a/libavfilter/af_afftdn.c
+++ b/libavfilter/af_afftdn.c
@@ -20,6 +20,7 @@
#include <float.h>
+#include "libavutil/avassert.h"
#include "libavutil/avstring.h"
#include "libavutil/channel_layout.h"
#include "libavutil/mem.h"
@@ -376,6 +377,8 @@ static void process_frame(AVFilterContext *ctx,
case AV_SAMPLE_FMT_DBLP:
noisy_data[i] = mag = hypot(fft_data_dbl[i].re, fft_data_dbl[i].im);
break;
+ default:
+ av_assert2(0);
}
power = mag * mag;
@@ -970,6 +973,8 @@ static void sample_noise_block(AudioFFTDeNoiseContext *s,
mag2 = fft_out_dbl[n].re * fft_out_dbl[n].re +
fft_out_dbl[n].im * fft_out_dbl[n].im;
break;
+ default:
+ av_assert2(0);
}
mag2 = fmax(mag2, s->sample_floor);
--
2.45.2
_______________________________________________
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".
^ permalink raw reply [flat|nested] 4+ messages in thread
* [FFmpeg-devel] [PATCH 2/3] avfilter/af_afir: Assert format
2024-06-10 19:09 [FFmpeg-devel] [PATCH 1/3] avfilter/af_afftdn: Assert format Michael Niedermayer
@ 2024-06-10 19:09 ` Michael Niedermayer
2024-06-10 19:09 ` [FFmpeg-devel] [PATCH 3/3] avfilter/af_amerge: Cleanup on av_channel_layout_copy() failure Michael Niedermayer
2024-07-07 20:16 ` [FFmpeg-devel] [PATCH 1/3] avfilter/af_afftdn: Assert format Michael Niedermayer
2 siblings, 0 replies; 4+ messages in thread
From: Michael Niedermayer @ 2024-06-10 19:09 UTC (permalink / raw)
To: FFmpeg development discussions and patches
Maybe helps: CID1516805 Uninitialized scalar variable
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
---
libavfilter/af_afir.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/libavfilter/af_afir.c b/libavfilter/af_afir.c
index 24f8f8cbf1c..4867bfba24b 100644
--- a/libavfilter/af_afir.c
+++ b/libavfilter/af_afir.c
@@ -25,6 +25,7 @@
#include <float.h>
+#include "libavutil/avassert.h"
#include "libavutil/cpu.h"
#include "libavutil/mem.h"
#include "libavutil/tx.h"
@@ -230,6 +231,8 @@ static int init_segment(AVFilterContext *ctx, AudioFIRSegment *seg, int selir,
iscale.d = 1.0 / sqrt(2.0 * part_size);
tx_type = AV_TX_DOUBLE_RDFT;
break;
+ default:
+ av_assert1(0);
}
for (int ch = 0; ch < ctx->inputs[0]->ch_layout.nb_channels && part_size >= 1; ch++) {
--
2.45.2
_______________________________________________
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".
^ permalink raw reply [flat|nested] 4+ messages in thread
* [FFmpeg-devel] [PATCH 3/3] avfilter/af_amerge: Cleanup on av_channel_layout_copy() failure
2024-06-10 19:09 [FFmpeg-devel] [PATCH 1/3] avfilter/af_afftdn: Assert format Michael Niedermayer
2024-06-10 19:09 ` [FFmpeg-devel] [PATCH 2/3] avfilter/af_afir: " Michael Niedermayer
@ 2024-06-10 19:09 ` Michael Niedermayer
2024-07-07 20:16 ` [FFmpeg-devel] [PATCH 1/3] avfilter/af_afftdn: Assert format Michael Niedermayer
2 siblings, 0 replies; 4+ messages in thread
From: Michael Niedermayer @ 2024-06-10 19:09 UTC (permalink / raw)
To: FFmpeg development discussions and patches
Fixes: CID1503088 Resource leak
Sponsored-by: Sovereign Tech Fund
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
---
libavfilter/af_amerge.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/libavfilter/af_amerge.c b/libavfilter/af_amerge.c
index 493c8521388..67c87d1d9e5 100644
--- a/libavfilter/af_amerge.c
+++ b/libavfilter/af_amerge.c
@@ -246,8 +246,11 @@ static int try_push_frame(AVFilterContext *ctx, int nb_samples)
av_make_q(1, outlink->sample_rate),
outlink->time_base);
- if ((ret = av_channel_layout_copy(&outbuf->ch_layout, &outlink->ch_layout)) < 0)
+ if ((ret = av_channel_layout_copy(&outbuf->ch_layout, &outlink->ch_layout)) < 0) {
+ free_frames(s->nb_inputs, inbuf);
+ av_frame_free(&outbuf);
return ret;
+ }
while (nb_samples) {
/* Unroll the most common sample formats: speed +~350% for the loop,
--
2.45.2
_______________________________________________
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".
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [FFmpeg-devel] [PATCH 1/3] avfilter/af_afftdn: Assert format
2024-06-10 19:09 [FFmpeg-devel] [PATCH 1/3] avfilter/af_afftdn: Assert format Michael Niedermayer
2024-06-10 19:09 ` [FFmpeg-devel] [PATCH 2/3] avfilter/af_afir: " Michael Niedermayer
2024-06-10 19:09 ` [FFmpeg-devel] [PATCH 3/3] avfilter/af_amerge: Cleanup on av_channel_layout_copy() failure Michael Niedermayer
@ 2024-07-07 20:16 ` Michael Niedermayer
2 siblings, 0 replies; 4+ messages in thread
From: Michael Niedermayer @ 2024-07-07 20:16 UTC (permalink / raw)
To: FFmpeg development discussions and patches
[-- Attachment #1.1: Type: text/plain, Size: 846 bytes --]
On Mon, Jun 10, 2024 at 09:09:54PM +0200, Michael Niedermayer wrote:
> Maybe helps: CID1515514 Uninitialized scalar variable
> Maybe helps: CID1515517 Uninitialized scalar variable
>
> Sponsored-by: Sovereign Tech Fund
> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
> ---
> libavfilter/af_afftdn.c | 5 +++++
> 1 file changed, 5 insertions(+)
will apply patchset
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Modern terrorism, a quick summary: Need oil, start war with country that
has oil, kill hundread thousand in war. Let country fall into chaos,
be surprised about raise of fundamantalists. Drop more bombs, kill more
people, be surprised about them taking revenge and drop even more bombs
and strip your own citizens of their rights and freedoms. to be continued
[-- 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".
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2024-07-07 20:16 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-06-10 19:09 [FFmpeg-devel] [PATCH 1/3] avfilter/af_afftdn: Assert format Michael Niedermayer
2024-06-10 19:09 ` [FFmpeg-devel] [PATCH 2/3] avfilter/af_afir: " Michael Niedermayer
2024-06-10 19:09 ` [FFmpeg-devel] [PATCH 3/3] avfilter/af_amerge: Cleanup on av_channel_layout_copy() failure Michael Niedermayer
2024-07-07 20:16 ` [FFmpeg-devel] [PATCH 1/3] avfilter/af_afftdn: Assert format Michael Niedermayer
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