# HG changeset patch # User moel.mich # Date 1375599286 0 # Node ID 07d44b20bbd4f91bcdaf1aa73ba7ec38fb63dae9 # Parent 3bba187d41c27464555d987e9e8204a4e6d74069 Fixed an issue in the NCT677X class causing a crash when calling Update. diff -r 3bba187d41c2 -r 07d44b20bbd4 Hardware/LPC/NCT677X.cs --- a/Hardware/LPC/NCT677X.cs Sat Aug 03 13:12:07 2013 +0000 +++ b/Hardware/LPC/NCT677X.cs Sun Aug 04 06:54:46 2013 +0000 @@ -20,6 +20,8 @@ private readonly Chip chip; + private readonly bool isNuvotonVendor; + private readonly float?[] voltages = new float?[0]; private readonly float?[] temperatures = new float?[0]; private readonly float?[] fans = new float?[0]; @@ -162,7 +164,10 @@ this.revision = revision; this.port = port; - if (!IsNuvotonVendor()) + + this.isNuvotonVendor = IsNuvotonVendor(); + + if (!isNuvotonVendor) return; switch (chip) { @@ -293,6 +298,9 @@ } public void SetControl(int index, byte? value) { + if (!isNuvotonVendor) + return; + if (index < 0 || index >= controls.Length) throw new ArgumentOutOfRangeException("index"); @@ -321,6 +329,9 @@ public float?[] Controls { get { return controls; } } public void Update() { + if (!isNuvotonVendor) + return; + if (!Ring0.WaitIsaBusMutex(10)) return; diff -r 3bba187d41c2 -r 07d44b20bbd4 Properties/AssemblyVersion.cs --- a/Properties/AssemblyVersion.cs Sat Aug 03 13:12:07 2013 +0000 +++ b/Properties/AssemblyVersion.cs Sun Aug 04 06:54:46 2013 +0000 @@ -10,5 +10,5 @@ using System.Reflection; -[assembly: AssemblyVersion("0.6.0.6")] -[assembly: AssemblyInformationalVersion("0.6.0.6 Alpha")] \ No newline at end of file +[assembly: AssemblyVersion("0.6.0.7")] +[assembly: AssemblyInformationalVersion("0.6.0.7 Alpha")] \ No newline at end of file