If compiling with Insure, mallocate a byte of memory and attach it to the
authorTim Potter <tpot@samba.org>
Thu, 4 Apr 2002 06:55:32 +0000 (06:55 +0000)
committerTim Potter <tpot@samba.org>
Thu, 4 Apr 2002 06:55:32 +0000 (06:55 +0000)
commit6dc80d625752f0a3ce6fd7b2278095529c6ec29f
tree57176f0c52aa33f03172d433940b4878087d62e8
parentb43256df5367fd16a0f6dcdf94fdbe8932cb77c9
If compiling with Insure, mallocate a byte of memory and attach it to the
POLICY_HND structure when passing new handles back from the appropriate
cli_* functions.  When closing the policy handle free the memory.

Insure (and indeed other memory checkers) should detect handles that have
not been closed properly as memory leaks.  Unfortunately this can only be
done when the program terminates (set insure++.summarize leaks in your
.psrc file) rather than when the policy handle falls out of scope.

Looks like Jeremy has squished all the policy handle leaks at the moment
but more are bound to crop up later.
source/include/rpc_misc.h
source/libsmb/cli_lsarpc.c
source/libsmb/cli_samr.c