Move RtlAreAllAccessesGranted, RtlAreAnyAccessesGranted and
RtlMapGenericMask to the shared runtime library.
Modified: trunk/reactos/lib/ntdll/makefile
Deleted: trunk/reactos/lib/ntdll/rtl/access.c
Added: trunk/reactos/lib/rtl/access.c
Modified: trunk/reactos/lib/rtl/makefile
Modified: trunk/reactos/ntoskrnl/se/access.c
_____
Modified: trunk/reactos/lib/ntdll/makefile
--- trunk/reactos/lib/ntdll/makefile 2005-04-20 20:48:55 UTC (rev
14722)
+++ trunk/reactos/lib/ntdll/makefile 2005-04-20 20:58:16 UTC (rev
14723)
@@ -63,7 +63,6 @@
rtl/i386/ftol.o
RTL_OBJECTS = \
- rtl/access.o \
rtl/apc.o \
rtl/atom.o \
rtl/callback.o \
_____
Deleted: trunk/reactos/lib/ntdll/rtl/access.c
--- trunk/reactos/lib/ntdll/rtl/access.c 2005-04-20 20:48:55 UTC
(rev 14722)
+++ trunk/reactos/lib/ntdll/rtl/access.c 2005-04-20 20:58:16 UTC
(rev 14723)
@@ -1,70 +0,0 @@
-/* $Id$
- *
- * COPYRIGHT: See COPYING in the top level directory
- * PROJECT: ReactOS kernel
- * PURPOSE: Access rights handling functions
- * FILE: lib/ntdll/rtl/access.c
- * PROGRAMER: Eric Kohl <ekohl(a)rz-online.de>
- * REVISION HISTORY:
- * 06/04/2000: Created
- */
-
-/* INCLUDES
*****************************************************************/
-
-#include <ddk/ntddk.h>
-
-#include <ntdll/ntdll.h>
-
-/* FUNCTIONS
***************************************************************/
-
-BOOLEAN
-STDCALL
-RtlAreAllAccessesGranted (
- ACCESS_MASK GrantedAccess,
- ACCESS_MASK DesiredAccess
- )
-{
- return ((GrantedAccess & DesiredAccess) == DesiredAccess);
-}
-
-
-/*
- * @implemented
- */
-BOOLEAN
-STDCALL
-RtlAreAnyAccessesGranted (
- ACCESS_MASK GrantedAccess,
- ACCESS_MASK DesiredAccess
- )
-{
- return ((GrantedAccess & DesiredAccess) != 0);
-}
-
-
-/*
- * @implemented
- */
-VOID
-STDCALL
-RtlMapGenericMask (
- PACCESS_MASK AccessMask,
- PGENERIC_MAPPING GenericMapping
- )
-{
- if (*AccessMask & GENERIC_READ)
- *AccessMask |= GenericMapping->GenericRead;
-
- if (*AccessMask & GENERIC_WRITE)
- *AccessMask |= GenericMapping->GenericWrite;
-
- if (*AccessMask & GENERIC_EXECUTE)
- *AccessMask |= GenericMapping->GenericExecute;
-
- if (*AccessMask & GENERIC_ALL)
- *AccessMask |= GenericMapping->GenericAll;
-
- *AccessMask &= 0x0FFFFFFF;
-}
-
-/* EOF */
_____
Added: trunk/reactos/lib/rtl/access.c
--- trunk/reactos/lib/rtl/access.c 2005-04-20 20:48:55 UTC (rev
14722)
+++ trunk/reactos/lib/rtl/access.c 2005-04-20 20:58:16 UTC (rev
14723)
@@ -0,0 +1,68 @@
+/*
+ * COPYRIGHT: See COPYING in the top level directory
+ * PROJECT: ReactOS kernel
+ * FILE: lib/rtl/access.c
+ * PURPOSE: Access rights handling functions
+ *
+ * PROGRAMMERS: Eric Kohl
+ */
+
+/* INCLUDES
*****************************************************************/
+
+#include <ddk/ntddk.h>
+#include <ntdll/rtl.h>
+
+#define NDEBUG
+#include <debug.h>
+
+/* FUNCTIONS
***************************************************************/
+
+/*
+ * @implemented
+ */
+BOOLEAN STDCALL
+RtlAreAllAccessesGranted(ACCESS_MASK GrantedAccess,
+ ACCESS_MASK DesiredAccess)
+{
+ PAGED_CODE_RTL();
+ return ((GrantedAccess & DesiredAccess) == DesiredAccess);
+}
+
+
+/*
+ * @implemented
+ */
+BOOLEAN STDCALL
+RtlAreAnyAccessesGranted(ACCESS_MASK GrantedAccess,
+ ACCESS_MASK DesiredAccess)
+{
+ PAGED_CODE_RTL();
+ return ((GrantedAccess & DesiredAccess) != 0);
+}
+
+
+/*
+ * @implemented
+ */
+VOID STDCALL
+RtlMapGenericMask(PACCESS_MASK AccessMask,
+ PGENERIC_MAPPING GenericMapping)
+{
+ PAGED_CODE_RTL();
+
+ if (*AccessMask & GENERIC_READ)
+ *AccessMask |= GenericMapping->GenericRead;
+
+ if (*AccessMask & GENERIC_WRITE)
+ *AccessMask |= GenericMapping->GenericWrite;
+
+ if (*AccessMask & GENERIC_EXECUTE)
+ *AccessMask |= GenericMapping->GenericExecute;
+
+ if (*AccessMask & GENERIC_ALL)
+ *AccessMask |= GenericMapping->GenericAll;
+
+ *AccessMask &= ~(GENERIC_READ | GENERIC_WRITE | GENERIC_EXECUTE |
GENERIC_ALL);
+}
+
+/* EOF */
_____
Modified: trunk/reactos/lib/rtl/makefile
--- trunk/reactos/lib/rtl/makefile 2005-04-20 20:48:55 UTC (rev
14722)
+++ trunk/reactos/lib/rtl/makefile 2005-04-20 20:58:16 UTC (rev
14723)
@@ -17,6 +17,7 @@
endif
TARGET_OBJECTS = \
+ access.o \
acl.o \
ppb.o \
bit.o \
_____
Modified: trunk/reactos/ntoskrnl/se/access.c
--- trunk/reactos/ntoskrnl/se/access.c 2005-04-20 20:48:55 UTC (rev
14722)
+++ trunk/reactos/ntoskrnl/se/access.c 2005-04-20 20:58:16 UTC (rev
14723)
@@ -1,11 +1,10 @@
-/* $Id$
- *
+/*
* COPYRIGHT: See COPYING in the top level directory
* PROJECT: ReactOS kernel
* FILE: ntoskrnl/se/access.c
- * PURPOSE: Access rights handling functions
- *
- * PROGRAMMERS: Eric Kohl <eric.kohl(a)t-online.de>
+ * PURPOSE: Access state functions
+ *
+ * PROGRAMMERS: Eric Kohl
*/
/* INCLUDES
*****************************************************************/
@@ -17,65 +16,6 @@
/* FUNCTIONS
***************************************************************/
/*
- * @implemented
- */
-BOOLEAN
-STDCALL
-RtlAreAllAccessesGranted (
- ACCESS_MASK GrantedAccess,
- ACCESS_MASK DesiredAccess
- )
-{
- PAGED_CODE_RTL();
-
- return ((GrantedAccess & DesiredAccess) == DesiredAccess);
-}
-
-
-/*
- * @implemented
- */
-BOOLEAN
-STDCALL
-RtlAreAnyAccessesGranted (
- ACCESS_MASK GrantedAccess,
- ACCESS_MASK DesiredAccess
- )
-{
- PAGED_CODE_RTL();
-
- return ((GrantedAccess & DesiredAccess) != 0);
-}
-
-
-/*
- * @implemented
- */
-VOID
-STDCALL
-RtlMapGenericMask (
- PACCESS_MASK AccessMask,
- PGENERIC_MAPPING GenericMapping
- )
-{
- PAGED_CODE_RTL();
-
- if (*AccessMask & GENERIC_READ)
- *AccessMask |= GenericMapping->GenericRead;
-
- if (*AccessMask & GENERIC_WRITE)
- *AccessMask |= GenericMapping->GenericWrite;
-
- if (*AccessMask & GENERIC_EXECUTE)
- *AccessMask |= GenericMapping->GenericExecute;
-
- if (*AccessMask & GENERIC_ALL)
- *AccessMask |= GenericMapping->GenericAll;
-
- *AccessMask &= ~(GENERIC_READ | GENERIC_WRITE | GENERIC_EXECUTE
| GENERIC_ALL);
-}
-
-/*
* @unimplemented
*/
NTSTATUS