netapi32: Set the buffer to NULL in NetApiBufferFree
juan.lang at gmail.com
Thu Jun 26 11:07:59 CDT 2008
> Not that I know anything but it seems that HeapFree calls RtlFreeHeap
> and RtlFreeHeap checks to make sure the pointer is not null before
> trying to free it. So explicitly setting it to null makes the erorr
> go away.
That might be true if setting Buffer to NULL happened before the call
to HeapFree, but it happens after. After the return from
NetApiBufferFree, Buffer goes out of scope, and a subsequent call
won't be affected by it.
So again, this seems like a Valgrind bug. How is the warning getting
silenced by this assignment?
More information about the wine-devel