Commit d614f1b4 authored by David L. Penton's avatar David L. Penton Committed by Nick Craver

If an UnauthorizedAccessException occurs and _disabled is set to true, ensure...

If an UnauthorizedAccessException occurs and _disabled is set to true, ensure subsequent calls to this method will not cause another UnauthorizedAccessException. (#589)
parent c6d8aec2
...@@ -335,7 +335,7 @@ public static bool TryGetSystemCPU(out float value) ...@@ -335,7 +335,7 @@ public static bool TryGetSystemCPU(out float value)
// this shouldn't happen, but just being safe... // this shouldn't happen, but just being safe...
} }
if (_cpu != null) if (!_disabled && _cpu != null)
{ {
value = _cpu.NextValue(); value = _cpu.NextValue();
return true; return true;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment