Alexandre Julliard : ntdll/tests: Fix a couple of test failures on limited user accounts.
Alexandre Julliard
julliard at wine.codeweavers.com
Tue Feb 9 10:46:47 CST 2016
Module: wine
Branch: master
Commit: b35642f5161f5c2016d3d25846ef23ec92bd87ec
URL: http://source.winehq.org/git/wine.git/?a=commit;h=b35642f5161f5c2016d3d25846ef23ec92bd87ec
Author: Alexandre Julliard <julliard at winehq.org>
Date: Tue Feb 9 12:01:30 2016 +0900
ntdll/tests: Fix a couple of test failures on limited user accounts.
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/ntdll/tests/reg.c | 15 +++++++++------
1 file changed, 9 insertions(+), 6 deletions(-)
diff --git a/dlls/ntdll/tests/reg.c b/dlls/ntdll/tests/reg.c
index 6957ef3..d00a496 100644
--- a/dlls/ntdll/tests/reg.c
+++ b/dlls/ntdll/tests/reg.c
@@ -591,8 +591,9 @@ static void test_NtCreateKey(void)
pRtlCreateUnicodeStringFromAsciiz( &str, "\\Registry\\Machine\\Software\\Classes" );
status = pNtCreateKey( &subkey, am, &attr, 0, 0, 0, 0 );
- ok( status == STATUS_SUCCESS, "NtCreateKey failed: 0x%08x\n", status );
- pNtClose( subkey );
+ ok( status == STATUS_SUCCESS || status == STATUS_ACCESS_DENIED,
+ "NtCreateKey failed: 0x%08x\n", status );
+ if (!status) pNtClose( subkey );
pRtlFreeUnicodeString( &str );
/* the REGISTRY part is case-sensitive unless OBJ_CASE_INSENSITIVE is specified */
@@ -605,14 +606,16 @@ static void test_NtCreateKey(void)
pRtlCreateUnicodeStringFromAsciiz( &str, "\\REGISTRY\\Machine\\Software\\Classes" );
status = pNtCreateKey( &subkey, am, &attr, 0, 0, 0, 0 );
- ok( status == STATUS_SUCCESS, "NtCreateKey failed: 0x%08x\n", status );
- pNtClose( subkey );
+ ok( status == STATUS_SUCCESS || status == STATUS_ACCESS_DENIED,
+ "NtCreateKey failed: 0x%08x\n", status );
+ if (!status) pNtClose( subkey );
pRtlFreeUnicodeString( &str );
pRtlCreateUnicodeStringFromAsciiz( &str, "\\REGISTRY\\MACHINE\\SOFTWARE\\CLASSES" );
status = pNtCreateKey( &subkey, am, &attr, 0, 0, 0, 0 );
- ok( status == STATUS_SUCCESS, "NtCreateKey failed: 0x%08x\n", status );
- pNtClose( subkey );
+ ok( status == STATUS_SUCCESS || status == STATUS_ACCESS_DENIED,
+ "NtCreateKey failed: 0x%08x\n", status );
+ if (!status) pNtClose( subkey );
pRtlFreeUnicodeString( &str );
pNtClose(key);
More information about the wine-cvs
mailing list