JanitorialProjects/ReplaceMalloc: remove malloc and free from dlls folder

Matteo Bruni matteo.mystral at gmail.com
Fri Dec 31 09:48:50 CST 2010


2010/12/30 Dan Kegel <dank at kegel.com>:
> Yegor wrote:
>> it's my first contribution to wine...
>
> Welcome!
>
>> so I wanted to start with some simple task.
>
> Changing memory allocation might not be simple.
>
> Your patch touches two different DLLs.
> You should probably split this patch up, one patch per dll.
>
> Also, the fact that your change to d3dcompiler_43 only
> changes a malloc and not a corresponding free is
> interesting.  Is there a leak?

That string is freed by wpp, which is a native library thus it uses
free(). So the code is correct as it is now, with the malloc(). There
were already a couple of times people came up with similar patches, I
can't find them right now though.

Maybe it's just time to remove the "replace malloc with HeapAlloc"
task from the wiki? Or, at least, add a note to explain that we expect
the current Wine code to be "compliant".



More information about the wine-devel mailing list