]> xenbits.xensource.com Git - pvdrivers/win/xenvif.git/commitdiff
Don't treat a missing Driver key as a hard failure
authorPaul Durrant <paul.durrant@citrix.com>
Tue, 8 Sep 2015 13:44:17 +0000 (14:44 +0100)
committerPaul Durrant <paul.durrant@citrix.com>
Tue, 8 Sep 2015 13:55:23 +0000 (14:55 +0100)
When looking to see whether an incumbent child driver will patch the
PDO names created by the new version of XENVIF, ignore any cases where
we find that the Driver key referenced in the Device key is actually
missing.

Signed-off-by: Paul Durrant <paul.durrant@citrix.com>
src/coinst/coinst.c

index 406fcaed22e75f8d596544c632678b2ba2f9ebba..825ba388791d1d872d4d2d20d22a6faf66e0c465 100644 (file)
@@ -817,23 +817,24 @@ SupportChildDrivers(
 
         Success = OpenDriverKey(DriverKeyName, &DriverKey);
         if (!Success)
-            goto fail7;
+            goto loop;
 
         Success = GetMatchingDeviceID(DriverKey, &MatchingDeviceID);
         if (!Success)
-            goto fail8;
+            goto fail7;
 
         Success = SupportDeviceID(MatchingDeviceID);
         if (!Success)
-            goto fail9;
+            goto fail8;
 
         free(MatchingDeviceID);
 
         RegCloseKey(DriverKey);
 
-        free(DriverKeyName);
-
     loop:
+        if (DriverKeyName != NULL)
+            free(DriverKeyName);
+
         RegCloseKey(DeviceKey);
     }
 
@@ -846,19 +847,16 @@ done:
 
     return TRUE;
 
-fail9:
-    Log("fail9");
-
-    free(MatchingDeviceID);
-
 fail8:
     Log("fail8");
 
-    RegCloseKey(DriverKey);
+    free(MatchingDeviceID);
 
 fail7:
     Log("fail7");
 
+    RegCloseKey(DriverKey);
+
     free(DriverKeyName);
 
 fail6: