X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;ds=sidebyside;f=libavfilter%2Faf_bs2b.c;h=b7cfd3815b0b21de74ad048bc687f1bb26596db4;hb=12791ec5b0d3653ad2a453d20368229f53df65c4;hp=54d52c5c6e9bd37f8b763ff8c1267bffbd16a7cc;hpb=7e503828b03804f90733c306154c293cbd15102e;p=ffmpeg diff --git a/libavfilter/af_bs2b.c b/libavfilter/af_bs2b.c index 54d52c5c6e9..b7cfd3815b0 100644 --- a/libavfilter/af_bs2b.c +++ b/libavfilter/af_bs2b.c @@ -45,7 +45,7 @@ typedef struct Bs2bContext { } Bs2bContext; #define OFFSET(x) offsetof(Bs2bContext, x) -#define A AV_OPT_FLAG_AUDIO_PARAM +#define A AV_OPT_FLAG_AUDIO_PARAM | AV_OPT_FLAG_FILTERING_PARAM static const AVOption bs2b_options[] = { { "profile", "Apply a pre-defined crossfeed level", @@ -134,8 +134,10 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *frame) out_frame = frame; } else { out_frame = ff_get_audio_buffer(inlink, frame->nb_samples); - if (!out_frame) + if (!out_frame) { + av_frame_free(&frame); return AVERROR(ENOMEM); + } av_frame_copy(out_frame, frame); ret = av_frame_copy_props(out_frame, frame); if (ret < 0) {