mirror of
https://github.com/reactos/reactos.git
synced 2025-02-25 09:50:02 +00:00
forgot to change some memory allocators calls
added comment to RtlFreeSid and changed its retval svn path=/trunk/; revision=9782
This commit is contained in:
parent
75a50813aa
commit
da670920b9
1 changed files with 10 additions and 12 deletions
|
@ -1,4 +1,4 @@
|
||||||
/* $Id: sid.c,v 1.1 2004/05/31 19:29:02 gdalsnes Exp $
|
/* $Id: sid.c,v 1.2 2004/06/20 23:30:47 gdalsnes Exp $
|
||||||
*
|
*
|
||||||
* COPYRIGHT: See COPYING in the top level directory
|
* COPYRIGHT: See COPYING in the top level directory
|
||||||
* PROJECT: ReactOS kernel
|
* PROJECT: ReactOS kernel
|
||||||
|
@ -212,9 +212,7 @@ RtlAllocateAndInitializeSid (
|
||||||
if (Sid == NULL)
|
if (Sid == NULL)
|
||||||
return STATUS_INVALID_PARAMETER;
|
return STATUS_INVALID_PARAMETER;
|
||||||
|
|
||||||
pSid = (PSID)RtlAllocateHeap (RtlGetProcessHeap (),
|
pSid = (PSID)ExAllocatePool(PagedPool, SubAuthorityCount * sizeof(DWORD) + 8);
|
||||||
0,
|
|
||||||
SubAuthorityCount * sizeof(DWORD) + 8);
|
|
||||||
if (pSid == NULL)
|
if (pSid == NULL)
|
||||||
return STATUS_NO_MEMORY;
|
return STATUS_NO_MEMORY;
|
||||||
|
|
||||||
|
@ -253,14 +251,16 @@ RtlAllocateAndInitializeSid (
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* @implemented
|
* @implemented
|
||||||
|
*
|
||||||
|
* RETURNS
|
||||||
|
* Docs says FreeSid does NOT return a value
|
||||||
|
* even thou it's defined to return a PVOID...
|
||||||
*/
|
*/
|
||||||
PSID STDCALL
|
PVOID STDCALL
|
||||||
RtlFreeSid(IN PSID Sid)
|
RtlFreeSid(IN PSID Sid)
|
||||||
{
|
{
|
||||||
RtlFreeHeap(RtlGetProcessHeap(),
|
ExFreePool(Sid);
|
||||||
0,
|
return NULL;
|
||||||
Sid);
|
|
||||||
return(Sid);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -327,9 +327,7 @@ RtlConvertSidToUnicodeString(PUNICODE_STRING String,
|
||||||
Length = (wcs - Buffer) * sizeof(WCHAR);
|
Length = (wcs - Buffer) * sizeof(WCHAR);
|
||||||
if (AllocateBuffer)
|
if (AllocateBuffer)
|
||||||
{
|
{
|
||||||
String->Buffer = RtlAllocateHeap (RtlGetProcessHeap (),
|
String->Buffer = ExAllocatePool(PagedPool,Length + sizeof(WCHAR));
|
||||||
0,
|
|
||||||
Length + sizeof(WCHAR));
|
|
||||||
if (String->Buffer == NULL)
|
if (String->Buffer == NULL)
|
||||||
return STATUS_NO_MEMORY;
|
return STATUS_NO_MEMORY;
|
||||||
String->MaximumLength = Length + sizeof(WCHAR);
|
String->MaximumLength = Length + sizeof(WCHAR);
|
||||||
|
|
Loading…
Reference in a new issue