We use real names here. This patch probably will not be committed until it is resubmitted.
Ops! I've mis-configured my mail client
The patch is also wrong.
Why? What difference does malloc() over HeapAlloc() make? (this is arguably a case for not sending the patch in the first place)
There is nothing that bugs me more than not being told why I'm wrong.
Peter
On 9 June 2010 19:08, Peter Davies ultratwo@gmail.com wrote:
We use real names here. This patch probably will not be committed until it is resubmitted.
Ops! I've mis-configured my mail client
The patch is also wrong.
Why? What difference does malloc() over HeapAlloc() make? (this is arguably a case for not sending the patch in the first place)
There is nothing that bugs me more than not being told why I'm wrong.
Where does the allocated variable get freed? Has that been changed from free to HeapFree?
Does it get realloced?
- Reece
On Wed, Jun 9, 2010 at 9:08 PM, Peter Davies ultratwo@gmail.com wrote:
The patch is also wrong.
Why? What difference does malloc() over HeapAlloc() make? (this is arguably a case for not sending the patch in the first place)
This is because wpp_lookup_mem is only referenced in the wpp_callbacks structure, which is passed to wpp_set_callbacks.
Code where callbacks are set and invoked is in libs/wpp/, which is a native library (will not compile to a dll), so it will clean up using standard free().
HeapAlloc/HeapFree should always be used in windows-based code, except when it interfaces with other code that doesn't. In any case, HeapAlloc/HeapFree and malloc/free should never be mixed up (allocate with one, free with the other).
Octavian