static int read_channels(AVFilterContext *ctx, int channels, uint8_t *item_str, int *nb, double **c, double **cache)

{

    char *p, *arg, *old_str, *prev_arg = NULL, *saveptr = NULL;

    int i, ret;



    p = old_str = av_strdup(item_str);

    if (!p)

        return AVERROR(ENOMEM);

    for (i = 0; i < channels; i++) {

        if (!(arg = av_strtok(p, "|", &saveptr)))

            arg = prev_arg;



        p = NULL;

        count_coefficients(arg, &nb[i]);

        cache[i] = av_calloc(nb[i], sizeof(cache[i]));

        c[i] = av_calloc(nb[i], sizeof(c[i]));

        if (!c[i] || !cache[i])

            return AVERROR(ENOMEM);



        ret = read_coefficients(ctx, arg, nb[i], c[i]);

        if (ret < 0)

            return ret;

        prev_arg = arg;

    }



    av_freep(&old_str);



    return 0;

}

static int read_channels(AVFilterContext *ctx, int channels, uint8_t *item_str, int *nb, double **c, double **cache)

{

    char *p, *arg, *old_str, *prev_arg = NULL, *saveptr = NULL;

    int i, ret;



    p = old_str = av_strdup(item_str);

    if (!p)

        return AVERROR(ENOMEM);

    for (i = 0; i < channels; i++) {

        if (!(arg = av_strtok(p, "|", &saveptr)))

            arg = prev_arg;



        p = NULL;

        count_coefficients(arg, &nb[i]);

        cache[i] = av_calloc(nb[i], sizeof(cache[i]));

        c[i] = av_calloc(nb[i], sizeof(c[i]));

        if (!c[i] || !cache[i])

            return AVERROR(ENOMEM);



        ret = read_coefficients(ctx, arg, nb[i], c[i]);

        if (ret < 0)

            return ret;

        prev_arg = arg;

    }



    av_freep(&old_str);



    return 0;

}

        p = NULL;         cache[i] = av_calloc(nb[i], sizeof(cache[i]));         c[i] = av_calloc(nb[i], sizeof(c[i]));
static int FUNC_0(AVFilterContext *VAR_0, int VAR_1, uint8_t *VAR_2, int *VAR_3, double **VAR_4, double **VAR_5)

{

    char *VAR_6, *VAR_7, *VAR_8, *VAR_9 = NULL, *VAR_10 = NULL;

    int VAR_11, VAR_12;



    VAR_6 = VAR_8 = av_strdup(VAR_2);

    if (!VAR_6)

        return AVERROR(ENOMEM);

    for (VAR_11 = 0; VAR_11 < VAR_1; VAR_11++) {

        if (!(VAR_7 = av_strtok(VAR_6, "|", &VAR_10)))

            VAR_7 = VAR_9;



        VAR_6 = NULL;

        count_coefficients(VAR_7, &VAR_3[VAR_11]);

        VAR_5[VAR_11] = av_calloc(VAR_3[VAR_11], sizeof(VAR_5[VAR_11]));

        VAR_4[VAR_11] = av_calloc(VAR_3[VAR_11], sizeof(VAR_4[VAR_11]));

        if (!VAR_4[VAR_11] || !VAR_5[VAR_11])

            return AVERROR(ENOMEM);



        VAR_12 = read_coefficients(VAR_0, VAR_7, VAR_3[VAR_11], VAR_4[VAR_11]);

        if (VAR_12 < 0)

            return VAR_12;

        VAR_9 = VAR_7;

    }



    av_freep(&VAR_8);



    return 0;

}

static int FUNC_0(AVFilterContext *VAR_0, int VAR_1, uint8_t *VAR_2, int *VAR_3, double **VAR_4, double **VAR_5)
{ char *VAR_6, *VAR_7, *VAR_8, *VAR_9 = NULL, *VAR_10 = NULL; int VAR_11, VAR_12; VAR_6 = VAR_8 = av_strdup(VAR_2); if (!VAR_6)
return AVERROR(ENOMEM); for (VAR_11 = 0; VAR_11 < VAR_1; VAR_11++) { if (!(VAR_7 = av_strtok(VAR_6, "|", &VAR_10)))
VAR_7 = VAR_9; VAR_6 = NULL; count_coefficients(VAR_7, &VAR_3[VAR_11]); VAR_5[VAR_11] = av_calloc(VAR_3[VAR_11], sizeof(VAR_5[VAR_11])); VAR_4[VAR_11] = av_calloc(VAR_3[VAR_11], sizeof(VAR_4[VAR_11])); if (!VAR_4[VAR_11] || !VAR_5[VAR_11])
return AVERROR(ENOMEM); VAR_12 = read_coefficients(VAR_0, VAR_7, VAR_3[VAR_11], VAR_4[VAR_11]); if (VAR_12 < 0)
return VAR_12; VAR_9 = VAR_7; } av_freep(&VAR_8); return 0; }