Juan Lang wrote:
Hi Dan,
- if (ppSecurityDescriptor)
*ppSecurityDescriptor = sd;
you leak sd in the (implicit) else block here. --Juan
There are no other options here. I'm sure windows will leak it as well. Did anyone mentioned already how well win32api is designed?
You can't free it since other pointers refer to it. Unless of course all the pointers are NULL. Only then descriptor can be freed.
Vitaliy.