]> mj.ucw.cz Git - pciutils.git/blobdiff - lib/i386-io-windows.h
Names: Fixed a rare bug in loading of pci.ids
[pciutils.git] / lib / i386-io-windows.h
index ef011b16fa2b15958a004363528e7015cee0861a..fd4030d9e7125942c58d4f12fe45ea39b99b0e81 100644 (file)
@@ -507,12 +507,14 @@ grant_process_token_dacl_permissions(HANDLE process, DWORD permissions, HANDLE *
 
   if (MySetSecurityInfo(*token, SE_KERNEL_OBJECT, DACL_SECURITY_INFORMATION, NULL, NULL, new_dacl, NULL) != ERROR_SUCCESS)
     {
+      LocalFree(new_dacl);
       LocalFree(*security_descriptor);
       LocalFree(owner);
       CloseHandle(*token);
       return FALSE;
     }
 
+  LocalFree(new_dacl);
   LocalFree(owner);
   return TRUE;
 }
@@ -1058,7 +1060,7 @@ SetProcessUserModeIOPL(VOID)
    */
 
   if (!LookupPrivilegeValue(NULL, SE_TCB_NAME, &luid_tcb_privilege))
-    goto err_not_implemented;
+    goto err_privilege_not_held;
 
   /*
    * If the current thread has already Tcb privilege enabled then there