Skip to content

An open-source remote desktop application designed for self-hosting, as an alternative to TeamViewer.

fix: report the CPU frequency in GHz with /1000, not /1024 (#16887)

Lukasf2c16e1e20fe
diff --git a/src/common.rs b/src/common.rs
index b8baf6e8a..4bc5bc2d0 100644
--- a/src/common.rs
+++ b/src/common.rs
@@ -970,7 +970,7 @@ pub fn get_sysinfo() -> serde_json::Value {
let cpu_name = cpus.first().map(|x| x.brand()).unwrap_or_default();
let cpu_name = cpu_name.trim_end();
let cpu_freq = cpus.first().map(|x| x.frequency()).unwrap_or_default();
- let cpu_freq = (cpu_freq as f64 / 1024. * 100.).round() / 100.;
+ let cpu_freq = (cpu_freq as f64 / 1000. * 100.).round() / 100.;
let cpu = if cpu_freq > 0. {
format!("{}, {}GHz, ", cpu_name, cpu_freq)
} else {