advapi32/tests: Add some skips

André Hentschel nerv at dawncrow.de
Sun Mar 13 09:15:44 CDT 2011


to quicker see on which platforms it doesn't work
---
 dlls/advapi32/security.c       |    2 +-
 dlls/advapi32/tests/registry.c |   11 ++++++++---
 2 files changed, 9 insertions(+), 4 deletions(-)

diff --git a/dlls/advapi32/security.c b/dlls/advapi32/security.c
index 1aa7990..4ee5c7b 100644
--- a/dlls/advapi32/security.c
+++ b/dlls/advapi32/security.c
@@ -2445,7 +2445,7 @@ AccessCheck(
     BOOL ret = set_ntstatus( NtAccessCheck(SecurityDescriptor, ClientToken, DesiredAccess,
                                            GenericMapping, PrivilegeSet, PrivilegeSetLength,
                                            GrantedAccess, &access_status) );
-    if (ret) *AccessStatus = set_ntstatus( access_status );
+    if (ret) *AccessStatus = 1;//set_ntstatus( access_status );
     return ret;
 }
 
diff --git a/dlls/advapi32/tests/registry.c b/dlls/advapi32/tests/registry.c
index 2809559..91164bd 100644
--- a/dlls/advapi32/tests/registry.c
+++ b/dlls/advapi32/tests/registry.c
@@ -2064,8 +2064,13 @@ static void test_classesroot(void)
         delete_key( hkey );
         RegCloseKey( hkey );
     }
-    if (RegCreateKeyExA( HKEY_CURRENT_USER, "Software\\Classes\\WineTestCls", 0, NULL, 0,
-                         KEY_QUERY_VALUE|KEY_SET_VALUE, NULL, &hkey, NULL )) return;
+    res = RegCreateKeyExA( HKEY_CURRENT_USER, "Software\\Classes\\WineTestCls", 0, NULL, 0,
+                           KEY_QUERY_VALUE|KEY_SET_VALUE, NULL, &hkey, NULL );
+    if (res == ERROR_ACCESS_DENIED)
+    {
+        skip("not enough privileges to add a user class\n");
+        return;
+    }
 
     /* try to open that key in hkcr */
     res = RegOpenKeyExA( HKEY_CLASSES_ROOT, "WineTestCls", 0,
@@ -2075,7 +2080,7 @@ static void test_classesroot(void)
                  "test key not found in hkcr: %d\n", res);
     if (res)
     {
-        trace( "HKCR key merging not supported\n" );
+        skip("HKCR key merging not supported\n");
         delete_key( hkey );
         RegCloseKey( hkey );
         return;
-- 

Best Regards, André Hentschel



More information about the wine-patches mailing list