fix premature close og reg key
authorGunnar Dalsnes <hardon@online.no>
Mon, 4 Jul 2005 22:22:22 +0000 (22:22 +0000)
committerGunnar Dalsnes <hardon@online.no>
Mon, 4 Jul 2005 22:22:22 +0000 (22:22 +0000)
svn path=/trunk/; revision=16417

reactos/lib/setupapi/devinst.c

index 58b00cb..b05d1c1 100644 (file)
@@ -1391,7 +1391,7 @@ BOOL WINAPI SetupDiInstallClassW(
        SetupCloseInfFile(hInf);
        return FALSE;
     }
-    RegCloseKey(hClassKey);
+
 
 
     /* Try to append a layout file */
@@ -1414,6 +1414,7 @@ BOOL WINAPI SetupDiInstallClassW(
        if (FileQueue == INVALID_HANDLE_VALUE)
        {
            SetupCloseInfFile(hInf);
+       RegCloseKey(hClassKey);
            return FALSE;
        }
 
@@ -1441,6 +1442,7 @@ BOOL WINAPI SetupDiInstallClassW(
 
     SetupCloseInfFile(hInf);
 
+    RegCloseKey(hClassKey);
     return TRUE;
 }