Added code to delete any kernel driver service that can't be opened before reinstalling it.
1.1 --- a/Hardware/Ring0.cs Tue Feb 08 22:02:29 2011 +0000
1.2 +++ b/Hardware/Ring0.cs Fri Feb 11 22:29:26 2011 +0000
1.3 @@ -112,7 +112,9 @@
1.4 driver.Open();
1.5
1.6 if (!driver.IsOpen) {
1.7 - // driver is not loaded, try to install and open
1.8 + // driver is not loaded, try to reinstall and open
1.9 +
1.10 + driver.Delete();
1.11 string fileName = Path.GetTempFileName();
1.12 if (ExtractDriver(fileName)) {
1.13 if (driver.Install(fileName)) {
1.14 @@ -124,7 +126,9 @@
1.15 report.AppendLine("Status: Opening driver failed");
1.16 }
1.17 } else {
1.18 - report.AppendLine("Status: Installing driver failed");
1.19 + report.AppendLine("Status: Installing driver \"" +
1.20 + fileName + "\" failed" +
1.21 + (File.Exists(fileName) ? " and file exists" : ""));
1.22 report.AppendLine();
1.23 report.Append("Exception: " + Marshal.GetExceptionForHR(
1.24 Marshal.GetHRForLastWin32Error()).Message);
2.1 --- a/Properties/AssemblyVersion.cs Tue Feb 08 22:02:29 2011 +0000
2.2 +++ b/Properties/AssemblyVersion.cs Fri Feb 11 22:29:26 2011 +0000
2.3 @@ -16,7 +16,7 @@
2.4
2.5 The Initial Developer of the Original Code is
2.6 Michael Möller <m.moeller@gmx.ch>.
2.7 - Portions created by the Initial Developer are Copyright (C) 2009-2010
2.8 + Portions created by the Initial Developer are Copyright (C) 2009-2011
2.9 the Initial Developer. All Rights Reserved.
2.10
2.11 Contributor(s):
2.12 @@ -37,5 +37,5 @@
2.13
2.14 using System.Reflection;
2.15
2.16 -[assembly: AssemblyVersion("0.2.1.12")]
2.17 -[assembly: AssemblyInformationalVersion("0.2.1.12 Alpha")]
2.18 \ No newline at end of file
2.19 +[assembly: AssemblyVersion("0.2.1.13")]
2.20 +[assembly: AssemblyInformationalVersion("0.2.1.13 Alpha")]
2.21 \ No newline at end of file