Author: weiden
Date: Wed Jul 18 14:50:55 2007
New Revision: 27715
URL:
http://svn.reactos.org/svn/reactos?rev=27715&view=rev
Log:
Make use of Set/QuerySecurityAccessMask
Modified:
trunk/reactos/dll/win32/ntmarta/ntmarta.c
Modified: trunk/reactos/dll/win32/ntmarta/ntmarta.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/ntmarta/ntmarta.…
==============================================================================
--- trunk/reactos/dll/win32/ntmarta/ntmarta.c (original)
+++ trunk/reactos/dll/win32/ntmarta/ntmarta.c Wed Jul 18 14:50:55 2007
@@ -581,20 +581,13 @@
case SE_WINDOW_OBJECT:
if (Write)
{
- if (SecurityInfo & (OWNER_SECURITY_INFORMATION |
GROUP_SECURITY_INFORMATION))
- DesiredAccess |= WRITE_OWNER;
- if (SecurityInfo & DACL_SECURITY_INFORMATION)
- DesiredAccess |= WRITE_DAC;
- if (SecurityInfo & SACL_SECURITY_INFORMATION)
- DesiredAccess |= ACCESS_SYSTEM_SECURITY;
+ SetSecurityAccessMask(SecurityInfo,
+ (PDWORD)&DesiredAccess);
}
else
{
- if (SecurityInfo & (OWNER_SECURITY_INFORMATION |
GROUP_SECURITY_INFORMATION |
- DACL_SECURITY_INFORMATION))
- DesiredAccess |= READ_CONTROL;
- if (SecurityInfo & SACL_SECURITY_INFORMATION)
- DesiredAccess |= ACCESS_SYSTEM_SECURITY;
+ QuerySecurityAccessMask(SecurityInfo,
+ (PDWORD)&DesiredAccess);
}
break;