Refresh sysinfo CPU

Without this now sysinfo `sys.processors().len()` returns 0.
This commit is contained in:
Frederick Zhang 2022-02-02 11:41:38 +11:00
parent d7dc710ddb
commit f54cc1a2cf
No known key found for this signature in database
GPG key ID: 980A192C361BE1AE

View file

@ -211,6 +211,7 @@ impl DataCollector {
#[cfg(not(target_os = "linux"))] #[cfg(not(target_os = "linux"))]
{ {
if self.widgets_to_harvest.use_proc { if self.widgets_to_harvest.use_proc {
self.sys.refresh_cpu();
self.sys.refresh_processes(); self.sys.refresh_processes();
} }
if self.widgets_to_harvest.use_temp { if self.widgets_to_harvest.use_temp {