From 608ac1e828f65130a7ac36794f7f7948206a1708 Mon Sep 17 00:00:00 2001 From: Rob Shearman Date: Mon, 18 Feb 2008 19:39:19 +0000 Subject: [PATCH] advapi32: Fix the AccessCheck tests so that the ACCESS_SYSTEM_SECURITY test now runs (when the user has the Security privilege). Duplicate the token at SecurityImpersonation impersonation level instead of SecurityIdentification, otherwise the call to RtlAdjustPrivilege fails on Windows. --- dlls/advapi32/tests/security.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/advapi32/tests/security.c b/dlls/advapi32/tests/security.c index 1cb3130a96b..5086cb70e54 100644 --- a/dlls/advapi32/tests/security.c +++ b/dlls/advapi32/tests/security.c @@ -784,7 +784,7 @@ static void test_AccessCheck(void) pRtlAdjustPrivilege(SE_SECURITY_PRIVILEGE, FALSE, TRUE, &Enabled); - res = DuplicateToken(ProcessToken, SecurityIdentification, &Token); + res = DuplicateToken(ProcessToken, SecurityImpersonation, &Token); ok(res, "DuplicateToken failed with error %d\n", GetLastError()); /* SD without owner/group */