[FFmpeg-devel] [PATCH v3 3/4] lavfi: check the validity of formats lists.

Moritz Barsnick barsnick at gmx.net
Fri Aug 28 11:01:29 EEST 2020


On Mon, Aug 24, 2020 at 13:36:50 +0200, Nicolas George wrote:
> +    switch (link->type) {
> +
> +        case AVMEDIA_TYPE_VIDEO:
> +            if ((ret = ff_formats_check_pixel_formats(log, cfg->formats)) < 0)
> +                return ret;
> +            break;
> +
> +        case AVMEDIA_TYPE_AUDIO:
> +            if ((ret = ff_formats_check_sample_formats(log, cfg->formats)) < 0 ||
> +                (ret = ff_formats_check_sample_rates(log, cfg->samplerates)) < 0 ||
> +                (ret = ff_formats_check_channel_layouts(log, cfg->channel_layouts)) < 0)
> +                return ret;
> +            break;
> +
> +        default:
> +            av_assert0(!"reached");
> +    }

"case" indentation is too large.

Moritz


More information about the ffmpeg-devel mailing list