static char *doubles2str(double *dp, int count, const char *sep)

{

    int i;

    char *ap, *ap0;

    int component_len = 15 + strlen(sep);

    if (!sep) sep = ", ";

    ap = av_malloc(component_len * count);

    if (!ap)

        return NULL;

    ap0   = ap;

    ap[0] = '\0';

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

        unsigned l = snprintf(ap, component_len, "%f%s", dp[i], sep);

        if(l >= component_len)

            return NULL;

        ap += l;

    }

    ap0[strlen(ap0) - strlen(sep)] = '\0';

    return ap0;

}

static char *doubles2str(double *dp, int count, const char *sep)

{

    int i;

    char *ap, *ap0;

    int component_len = 15 + strlen(sep);

    if (!sep) sep = ", ";

    ap = av_malloc(component_len * count);

    if (!ap)

        return NULL;

    ap0   = ap;

    ap[0] = '\0';

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

        unsigned l = snprintf(ap, component_len, "%f%s", dp[i], sep);

        if(l >= component_len)

            return NULL;

        ap += l;

    }

    ap0[strlen(ap0) - strlen(sep)] = '\0';

    return ap0;

}

        if(l >= component_len)
static char *FUNC_0(double *VAR_0, int VAR_1, const char *VAR_2)

{

    int VAR_3;

    char *VAR_4, *VAR_5;

    int VAR_6 = 15 + strlen(VAR_2);

    if (!VAR_2) VAR_2 = ", ";

    VAR_4 = av_malloc(VAR_6 * VAR_1);

    if (!VAR_4)

        return NULL;

    VAR_5   = VAR_4;

    VAR_4[0] = '\0';

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

        unsigned VAR_7 = snprintf(VAR_4, VAR_6, "%f%s", VAR_0[VAR_3], VAR_2);

        if(VAR_7 >= VAR_6)

            return NULL;

        VAR_4 += VAR_7;

    }

    VAR_5[strlen(VAR_5) - strlen(VAR_2)] = '\0';

    return VAR_5;

}

static char *FUNC_0(double *VAR_0, int VAR_1, const char *VAR_2)
{ int VAR_3; char *VAR_4, *VAR_5; int VAR_6 = 15 + strlen(VAR_2); if (!VAR_2) VAR_2 = ", "; VAR_4 = av_malloc(VAR_6 * VAR_1); if (!VAR_4)
return NULL; VAR_5   = VAR_4; VAR_4[0] = '\0'; for (VAR_3 = 0; VAR_3 < VAR_1; VAR_3++) { unsigned VAR_7 = snprintf(VAR_4, VAR_6, "%f%s", VAR_0[VAR_3], VAR_2); if(VAR_7 >= VAR_6)
return NULL; VAR_4 += VAR_7; } VAR_5[strlen(VAR_5) - strlen(VAR_2)] = '\0'; return VAR_5; }