Skip to content

Commit

Permalink
Update SystemInfoHelper.Windows.cs
Browse files Browse the repository at this point in the history
  • Loading branch information
laolarou726 committed Nov 11, 2023
1 parent fb5a71e commit c7dfa9d
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public static class SystemInfoHelper
{
static readonly PerformanceCounter FreeMemCounter = new("Memory", "Available MBytes");
static readonly PerformanceCounter MemUsagePercentageCounter = new("Memory", "% Committed Bytes In Use");
static readonly PerformanceCounter CpuCounter = new("Processor Information", "% Processor Utility", "_Total");
static readonly PerformanceCounter CpuCounter = new("Processor", "% Processor Time", "_Total");

static SystemInfoHelper()
{
Expand Down Expand Up @@ -231,7 +231,7 @@ public static CPUInfo GetWindowsCpuUsage()
return new CPUInfo
{
Name = "Total %",
Usage = percentage
Usage = percentage > 100 ? 100 : percentage
};
}

Expand Down

0 comments on commit c7dfa9d

Please sign in to comment.