[SETUPAPI]
authorAmine Khaldi <amine.khaldi@reactos.org>
Sat, 14 Jan 2012 15:47:59 +0000 (15:47 +0000)
committerAmine Khaldi <amine.khaldi@reactos.org>
Sat, 14 Jan 2012 15:47:59 +0000 (15:47 +0000)
* Apply a default date of 00/00/0000 when DriverVer is missing. Should fix installation of drivers which do not provide a DriverVer directive.
See issue #6676 for more details.

svn path=/trunk/; revision=54958

reactos/dll/win32/setupapi/driver.c

index 9b65943..0e14f03 100644 (file)
@@ -390,8 +390,13 @@ GetVersionInformationFromInfFile(
             DriverVer, RequiredSize,
             &RequiredSize);
     }
-    if (!Result)
-        goto cleanup;
+    else
+    {
+        /* windows sets default date of 00/00/0000 when this directive is missing*/
+        memset(DriverDate, 0, sizeof(FILETIME));
+        *DriverVersion = 0;
+        return TRUE;
+    }
 
     /* Get driver date and driver version, by analyzing the "DriverVer" value */
     pComma = strchrW(DriverVer, ',');