diff options
Diffstat (limited to 'libavfilter/af_stereowiden.c')
-rw-r--r-- | libavfilter/af_stereowiden.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/libavfilter/af_stereowiden.c b/libavfilter/af_stereowiden.c index 7c5f2d4..154a8b1 100644 --- a/libavfilter/af_stereowiden.c +++ b/libavfilter/af_stereowiden.c @@ -55,15 +55,15 @@ static int query_formats(AVFilterContext *ctx) { AVFilterFormats *formats = NULL; AVFilterChannelLayouts *layout = NULL; + int ret; - ff_add_format(&formats, AV_SAMPLE_FMT_FLT); - ff_set_common_formats(ctx, formats); - ff_add_channel_layout(&layout, AV_CH_LAYOUT_STEREO); - ff_set_common_channel_layouts(ctx, layout); + if ((ret = ff_add_format (&formats, AV_SAMPLE_FMT_FLT )) < 0 || + (ret = ff_set_common_formats (ctx , formats )) < 0 || + (ret = ff_add_channel_layout (&layout , AV_CH_LAYOUT_STEREO)) < 0 || + (ret = ff_set_common_channel_layouts (ctx , layout )) < 0) + return ret; formats = ff_all_samplerates(); - if (!formats) - return AVERROR(ENOMEM); return ff_set_common_samplerates(ctx, formats); } |