void *av_fast_realloc(void *ptr, unsigned int *size, size_t min_size)

{

    if (min_size < *size)

        return ptr;



    min_size = FFMAX(min_size + min_size / 16 + 32, min_size);



    ptr = av_realloc(ptr, min_size);

    /* we could set this to the unmodified min_size but this is safer

     * if the user lost the ptr and uses NULL now

     */

    if (!ptr)

        min_size = 0;



    *size = min_size;



    return ptr;

}

void *av_fast_realloc(void *ptr, unsigned int *size, size_t min_size)

{

    if (min_size < *size)

        return ptr;



    min_size = FFMAX(min_size + min_size / 16 + 32, min_size);



    ptr = av_realloc(ptr, min_size);

    





    if (!ptr)

        min_size = 0;



    *size = min_size;



    return ptr;

}

void *FUNC_0(void *VAR_0, unsigned int *VAR_1, size_t VAR_2)

{

    if (VAR_2 < *VAR_1)

        return VAR_0;



    VAR_2 = FFMAX(VAR_2 + VAR_2 / 16 + 32, VAR_2);



    VAR_0 = av_realloc(VAR_0, VAR_2);

    





    if (!VAR_0)

        VAR_2 = 0;



    *VAR_1 = VAR_2;



    return VAR_0;

}

void *FUNC_0(void *VAR_0, unsigned int *VAR_1, size_t VAR_2)
{ if (VAR_2 < *VAR_1)
return VAR_0; VAR_2 = FFMAX(VAR_2 + VAR_2 / 16 + 32, VAR_2); VAR_0 = av_realloc(VAR_0, VAR_2); if (!VAR_0)
VAR_2 = 0; *VAR_1 = VAR_2; return VAR_0; }