static void copy_parameter_set(void **to, void **from, int count, int size)
{
    int i;
    for (i=0; i<count; i++){
        if (to[i] && !from[i]) av_freep(&to[i]);
        else if (from[i] && !to[i]) to[i] = av_malloc(size);
        if (from[i]) memcpy(to[i], from[i], size);
    }
}
['static void copy_parameter_set(void **to, void **from, int count, int size)\n{\n    int i;\n    for (i=0; i<count; i++){\n        if (to[i] && !from[i]) av_freep(&to[i]);\n        else if (from[i] && !to[i]) to[i] = av_malloc(size);\n        if (from[i]) memcpy(to[i], from[i], size);\n    }\n}', 'void *av_malloc(size_t size)\n{\n    void *ptr = NULL;\n#if CONFIG_MEMALIGN_HACK\n    long diff;\n#endif\n    if(size > (INT_MAX-32) )\n        return NULL;\n#if CONFIG_MEMALIGN_HACK\n    ptr = malloc(size+32);\n    if(!ptr)\n        return ptr;\n    diff= ((-(long)ptr - 1)&31) + 1;\n    ptr = (char*)ptr + diff;\n    ((char*)ptr)[-1]= diff;\n#elif HAVE_POSIX_MEMALIGN\n    if (posix_memalign(&ptr,32,size))\n        ptr = NULL;\n#elif HAVE_MEMALIGN\n    ptr = memalign(32,size);\n#else\n    ptr = malloc(size);\n#endif\n    return ptr;\n}']