[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [win-pv-devel] [PATCH for 8.1] Don't treat a missing Driver key as a hard failure
When looking to see whether an incumbent child driver will patch the PDO names created by the new version of XENBUS, 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@xxxxxxxxxx> --- src/coinst/coinst.c | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) This needs to be back-ported to 8.1 diff --git a/src/coinst/coinst.c b/src/coinst/coinst.c index 68e3265..09ef847 100644 --- a/src/coinst/coinst.c +++ b/src/coinst/coinst.c @@ -704,7 +704,7 @@ found: Success = OpenDriverKey(DriverKeyName, &DriverKey); if (!Success) - goto fail5; + goto done; Error = RegQueryInfoKey(DriverKey, NULL, @@ -720,14 +720,14 @@ found: NULL); if (Error != ERROR_SUCCESS) { SetLastError(Error); - goto fail6; + goto fail5; } DriverDescLength = MaxValueLength + sizeof (TCHAR); DriverDesc = calloc(1, DriverDescLength); if (DriverDesc == NULL) - goto fail7; + goto fail6; Error = RegQueryValueEx(DriverKey, "DriverDesc", @@ -740,12 +740,12 @@ found: goto done; SetLastError(Error); - goto fail8; + goto fail7; } if (Type != REG_SZ) { SetLastError(ERROR_BAD_FORMAT); - goto fail9; + goto fail8; } ProductNameLength = (DWORD)strlen(PRODUCT_NAME_STR); @@ -754,13 +754,13 @@ found: PRODUCT_NAME_STR, ProductNameLength) != 0) { SetLastError(ERROR_INSTALL_FAILURE); - goto fail10; + goto fail9; } if (strcmp(DriverDesc + ProductNameLength, " PV Bus") != 0) { SetLastError(ERROR_INSTALL_FAILURE); - goto fail11; + goto fail10; } done: @@ -781,9 +781,6 @@ done: return TRUE; -fail11: - Log("fail11"); - fail10: Log("fail10"); @@ -793,19 +790,19 @@ fail9: fail8: Log("fail8"); - free(DriverDesc); - fail7: Log("fail7"); + free(DriverDesc); + fail6: Log("fail6"); - RegCloseKey(DriverKey); - fail5: Log("fail5"); + RegCloseKey(DriverKey); + free(DriverKeyName); fail4: -- 2.1.1 _______________________________________________ win-pv-devel mailing list win-pv-devel@xxxxxxxxxxxxxxxxxxxx http://lists.xenproject.org/cgi-bin/mailman/listinfo/win-pv-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |