summaryrefslogtreecommitdiffstats
path: root/win/CS/HandBrake.ApplicationServices
diff options
context:
space:
mode:
authorsr55 <[email protected]>2017-07-28 20:24:53 +0100
committersr55 <[email protected]>2017-07-28 20:25:13 +0100
commit45a24df1088286699f4788c3a0408e641d049970 (patch)
tree94942a899931bf2ea3563a1d8297db92758f9c90 /win/CS/HandBrake.ApplicationServices
parent710b8c864556a5324683ea8bdf9d7fd4ef9dd7c5 (diff)
WinGui: Fix an issue that was causing the handles to the scan libhb instance to be recycle'd while it was still in use. Fixes #844 and #836
Diffstat (limited to 'win/CS/HandBrake.ApplicationServices')
-rw-r--r--win/CS/HandBrake.ApplicationServices/Utilities/VersionHelper.cs9
1 files changed, 3 insertions, 6 deletions
diff --git a/win/CS/HandBrake.ApplicationServices/Utilities/VersionHelper.cs b/win/CS/HandBrake.ApplicationServices/Utilities/VersionHelper.cs
index 40aca7d3e..3d7943d83 100644
--- a/win/CS/HandBrake.ApplicationServices/Utilities/VersionHelper.cs
+++ b/win/CS/HandBrake.ApplicationServices/Utilities/VersionHelper.cs
@@ -9,9 +9,6 @@
namespace HandBrake.ApplicationServices.Utilities
{
- using System;
- using System.Reflection;
-
using HandBrake.ApplicationServices.Interop;
using HandBrake.ApplicationServices.Interop.Interfaces;
@@ -28,14 +25,14 @@ namespace HandBrake.ApplicationServices.Utilities
/// </returns>
public static string GetVersion()
{
- IHandBrakeInstance instance = HandBrakeInstanceManager.GetScanInstance(1);
+ IHandBrakeInstance instance = HandBrakeInstanceManager.MasterInstance;
return IsNightly() ? string.Format("Nightly {0} ({1})", instance.Version, instance.Build) : string.Format("{0} ({1})", instance.Version, instance.Build);
}
public static string GetVersionShort()
{
- IHandBrakeInstance instance = HandBrakeInstanceManager.GetScanInstance(1);
+ IHandBrakeInstance instance = HandBrakeInstanceManager.MasterInstance;
return string.Format("{0} {1}", instance.Version, instance.Build);
}
@@ -47,7 +44,7 @@ namespace HandBrake.ApplicationServices.Utilities
/// </returns>
public static bool IsNightly()
{
- IHandBrakeInstance instance = HandBrakeInstanceManager.GetScanInstance(1);
+ IHandBrakeInstance instance = HandBrakeInstanceManager.MasterInstance;
// 01 = Unofficial Builds. 00 = Official Tagged Releases.
return instance.Build.ToString().EndsWith("01");