* sec_helper.cc (security_descriptor::realloc): Call free first if
current security desriptor has been allocated by GetSecurityInfo.
This commit is contained in:
parent
b42441d32b
commit
7c16c02dbb
@ -1,3 +1,8 @@
|
|||||||
|
2009-10-31 Corinna Vinschen <corinna@vinschen.de>
|
||||||
|
|
||||||
|
* sec_helper.cc (security_descriptor::realloc): Call free first if
|
||||||
|
current security desriptor has been allocated by GetSecurityInfo.
|
||||||
|
|
||||||
2009-10-30 Corinna Vinschen <corinna@vinschen.de>
|
2009-10-30 Corinna Vinschen <corinna@vinschen.de>
|
||||||
|
|
||||||
* sec_helper.cc (security_descriptor::free): If sd_size is 0, call
|
* sec_helper.cc (security_descriptor::free): If sd_size is 0, call
|
||||||
|
@ -288,6 +288,9 @@ security_descriptor::realloc (size_t nsize)
|
|||||||
{
|
{
|
||||||
PSECURITY_DESCRIPTOR tmp;
|
PSECURITY_DESCRIPTOR tmp;
|
||||||
|
|
||||||
|
/* Can't re-use buffer allocated by GetSecurityInfo. */
|
||||||
|
if (psd && !sd_size)
|
||||||
|
free ();
|
||||||
if (!(tmp = (PSECURITY_DESCRIPTOR) ::realloc (psd, nsize)))
|
if (!(tmp = (PSECURITY_DESCRIPTOR) ::realloc (psd, nsize)))
|
||||||
return NULL;
|
return NULL;
|
||||||
sd_size = nsize;
|
sd_size = nsize;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user