update for HEAD-2003091401
[reactos.git] / lib / ntdll / rtl / luid.c
1 /* $Id$
2  *
3  * COPYRIGHT:         See COPYING in the top level directory
4  * PROJECT:           ReactOS kernel
5  * PURPOSE:           Locally unique identifier (LUID) helper functions
6  * FILE:              lib/ntdll/rtl/luid.c
7  * PROGRAMER:         Eric Kohl <ekohl@zr-online.de>
8  * REVISION HISTORY:
9  *                    15/04/2000: Created
10  */
11
12 /* INCLUDES *****************************************************************/
13
14 #include <ddk/ntddk.h>
15
16
17 /* FUNCTIONS *****************************************************************/
18
19 VOID STDCALL
20 RtlCopyLuid(PLUID LuidDest,
21             PLUID LuidSrc)
22 {
23   LuidDest->LowPart = LuidSrc->LowPart;
24   LuidDest->HighPart = LuidSrc->HighPart;
25 }
26
27
28 /*
29  * @implemented
30  */
31 VOID STDCALL
32 RtlCopyLuidAndAttributesArray(ULONG Count,
33                               PLUID_AND_ATTRIBUTES Src,
34                               PLUID_AND_ATTRIBUTES Dest)
35 {
36   ULONG i;
37
38   for (i = 0; i < Count; i++)
39     {
40       RtlCopyMemory(&Dest[i],
41                     &Src[i],
42                     sizeof(LUID_AND_ATTRIBUTES));
43     }
44 }
45
46
47 /*
48  * @implemented
49  */
50 BOOLEAN STDCALL
51 RtlEqualLuid(PLUID Luid1,
52              PLUID Luid2)
53 {
54   return (Luid1->LowPart == Luid2->LowPart &&
55           Luid1->HighPart == Luid2->HighPart);
56 }
57
58 /* EOF */