wintrust: Set system attribute on the target catalog file in CryptCATAdminAddCatalog. (try 2)

Hans Leidekker hans at codeweavers.com
Tue Jan 20 10:12:09 CST 2009


See http://bugs.winehq.org/show_bug.cgi?id=17020

Paul Vriens has a test to show that this is what native does.

 -Hans

diff --git a/dlls/wintrust/crypt.c b/dlls/wintrust/crypt.c
index cf8aa73..e01a230 100644
--- a/dlls/wintrust/crypt.c
+++ b/dlls/wintrust/crypt.c
@@ -188,6 +188,8 @@ HCATINFO WINAPI CryptCATAdminAddCatalog(HCATADMIN catAdmin, PWSTR catalogFile,
         HeapFree(GetProcessHeap(), 0, target);
         return NULL;
     }
+    SetFileAttributesW(target, FILE_ATTRIBUTE_SYSTEM);
+
     if (!(ci = HeapAlloc(GetProcessHeap(), 0, sizeof(*ci))))
     {
         HeapFree(GetProcessHeap(), 0, target);



More information about the wine-patches mailing list