More parameter checking in RltCopySid.

This commit is contained in:
Juergen Schmied 1998-10-23 12:06:19 +00:00 committed by Alexandre Julliard
parent 4a84dc2391
commit c595083f2b
1 changed files with 2 additions and 1 deletions

View File

@ -254,7 +254,8 @@ LPBYTE WINAPI RtlSubAuthorityCountSid(LPSID lpsid)
* RtlCopySid [NTDLL.302]
*/
DWORD WINAPI RtlCopySid(DWORD len,LPSID to,LPSID from)
{
{ if (!from)
return 0;
if (len<(from->SubAuthorityCount*4+8))
return STATUS_BUFFER_TOO_SMALL;
memmove(to,from,from->SubAuthorityCount*4+8);