summaryrefslogtreecommitdiff
path: root/libavfilter/af_aphaser.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavfilter/af_aphaser.c')
-rw-r--r--libavfilter/af_aphaser.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/libavfilter/af_aphaser.c b/libavfilter/af_aphaser.c
index 708b568c74..b08570f90a 100644
--- a/libavfilter/af_aphaser.c
+++ b/libavfilter/af_aphaser.c
@@ -94,23 +94,26 @@ static int query_formats(AVFilterContext *ctx)
AV_SAMPLE_FMT_S16, AV_SAMPLE_FMT_S16P,
AV_SAMPLE_FMT_NONE
};
+ int ret;
layouts = ff_all_channel_layouts();
if (!layouts)
return AVERROR(ENOMEM);
- ff_set_common_channel_layouts(ctx, layouts);
+ ret = ff_set_common_channel_layouts(ctx, layouts);
+ if (ret < 0)
+ return ret;
formats = ff_make_format_list(sample_fmts);
if (!formats)
return AVERROR(ENOMEM);
- ff_set_common_formats(ctx, formats);
+ ret = ff_set_common_formats(ctx, formats);
+ if (ret < 0)
+ return ret;
formats = ff_all_samplerates();
if (!formats)
return AVERROR(ENOMEM);
- ff_set_common_samplerates(ctx, formats);
-
- return 0;
+ return ff_set_common_samplerates(ctx, formats);
}
#define MOD(a, b) (((a) >= (b)) ? (a) - (b) : (a))